4

Is there a way to compare the current state of a file (in working directory) with what the file looked like when it was commited (eg. five commits ago)?

TMOTTM
  • 2,984
  • 5
  • 26
  • 48

1 Answers1

3

Do a git log, then copy SHA id of the commit. Then run git diff command with this id, for example:

git diff (sha-id) filename
jschnasse
  • 7,020
  • 4
  • 27
  • 59