1

Using git, how do I see a file at a specific revision without checking it out?

I've asked this question a thousand times and can never remember the obscure way git goes about it.

0

1 Answer 1

1
git show rev:path

rev is a revision specified according to the rules in git-rev-parse(1); e.g. a commit hash or a brach name.

path is the path to a file; relative to the repository root by default, but relative to current directory if prefixed with ./.

1
  • What and by commit you mean the commit code? And by file the file's name? Or its path? Can you expand your answer a little?
    – slhck
    Jun 16, 2012 at 18:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .