How to show what a commit did?
git show <commit-id>
Documentation for git show
Does
$ git log -p
do what you need?
Check out the chapter on Git Log in the Git Community Book for more examples. (Or look at the the documentation.)
Update: As others (Jakub and Bombe) already pointed out: although the above works, git show is actually the command that is intended to do exactly what was asked for.
TL;DR
git show <commit>
Show
To show what a commit did with stats:
git show <commit> --stat
Log
To show commit log with differences introduced for each commit in a range:
git log -p <commit1> <commit2>
What is <commit>
?
Each commit has a unique id we reference here as <commit>
. The unique id is an SHA-1 hash – a checksum of the content you’re storing plus a header. #TMI
If you don't know your <commit>
:
git log
to view the commit historyFind the commit you care about.