A colleague of mine checked in some changes to Git, and I want to see exactly what those changes were. In other words, the diff between his check-in and its parent.
git diff shaOfHisCheckIn shaOfHisCheckIn^
git show
is your friend:
git show shaOfHisCheckIn
If you want to view the diff visually in kdiff3
, meld
, kompare
, xxdiff
, tkdiff
, diffuse
…
git difftool --dir-diff shaOfHisCheckIn^!
git difftool --tool=meld --dir-diff shaOfHisCheckIn^!
git difftool -t meld -d shaOfHisCheckIn^!
Try this:
git diff shaOfHisCheckIn^ shaOfHisCheckIn
or
git diff shaOfHisCheckIn{^,}