5

Is there any way to find out what an entire file looked like in a particular commit after applying all changes to it? I know there is a difference between 2 files(what was added and removed) and that's what shown in git. But that's not what I'm looking for.

Incerteza
  • 32,326
  • 47
  • 154
  • 261

1 Answers1

10

If you know the commit id you can checkout the specific file like below:

git checkout <commitid> yourfile

EDIT

If you don't want to modify your local version use:

git show <commitid>:filename
Saravana
  • 37,852
  • 18
  • 100
  • 108