Thread (1 message) 1 message, 1 author, 2021-03-12

Re: [PATCH] [GSOC][RFC] format-patch: pass --right-only to range-diff

From: Junio C Hamano <hidden>
Date: 2021-03-12 22:10:14

Junio C Hamano [off-list ref] writes:
Taylor Blau [off-list ref] writes:
quoted
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.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help