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

Re: Deprecating git diff ..; dealing with other ranges

From: Junio C Hamano <hidden>
Date: 2019-03-12 07:22:12

Denton Liu [off-list ref] writes:
=>		content="$(git diff HEAD^! | tail -n 1)"
...
It gets caught in my attempt to only deprecate ..'s. Technically, it's
undocumented behaviour and it only happens to work because git-diff
accept ranges but it doesn't operate in an intuitive way.
It reuses the same notation as that is used for ranges, but makes
the notation mean something entirely different from ranges, because
"diff" is about two endpoints.

And "git diff ^A B" (or "git diff B ^A") works like "git diff A B".
So does "git diff A^!", for a single-parent commit A, work like "git
diff A^ A".
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help