Andreas Schwab [off-list ref] writes:
Junio C Hamano [off-list ref] writes:
quoted
I encountered another example yesterday after sending the above message
[*1*]. I was fixing one small bug, and had a commit that updates code and
adds a test vector. It is a single commit on top of the current branch
tip, which allegedly as a buggy code.
Then I wanted to double check that the bug really existed before the fix.
git checkout HEAD^
git show @{-1} t/ | git apply
Alternative:
git checkout @{-1} t/
True in this case, but that is usable when "diff @{-1}^ @{-1}" happens to
be the _only_ change to your current state, so it won't be a general
substitute for the "diff | apply" pipeline.