Re: [PATCH] [GSOC][RFC] format-patch: pass --right-only to range-diff
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Mar 12, 2021, 22:09 UTC
- Message-ID
- <xmqqv99w58iq.fsf@gitster.g>
- In-Reply-To
- <xmqq1rck6nr8.fsf@gitster.g>
Junio C Hamano <gitster@pobox.com> writes:
Show 21 quoted lines
> Taylor Blau <ttaylorr@github.com> writes: > >> Note that I think (and Johannes--cc'd--could confirm) that what you want >> is '--left-only' to discard rebased changes from the upstream branch: > > Does that mean range-diff got --left-only and --right-only > backwards? IOW, doesn't > > $ git log --left-only A...B > > show what is shown in "git log B..A", and if so, shouldn't > > $ git range-diff --left-only A...B > > which is a synonym for > > $ git range-diff B..A A..B > > also give commits in the B..A range? > > Puzzled....
Ah, it was only that "range-diff --help" uses confusing double-negative phrasing. I.e.
--left-only::
Suppress commits that are missing from the first specified range
(or the "left range" when using the `<rev1>...<rev2>` format).If you "suppress those that are missing from X", you are effectively including only those that appear in X, so two conclusions I draw are
- "range-diff" does not get "--left/right-only" backwards;
- its documentation should be improved.
Perhaps
--left-only:: Include only commits that are in the first range (or the "left range" when using the `<rev1>...<rev2>` format).
wouldn't have made me puzzled.
Thanks.