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
  • 3,286
  • 6
  • 32
  • 63

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
  • 8,526
  • 6
  • 32
  • 72