Jonas Byström Jonas Byström - 6 months ago 26
Git Question

List and cat files at certain commit

Is it possible in git to list all files in a directory at a certain commit, not just the changes? I'd like to not having to update my working tree (i.e.

git checkout

In the same spirit I'm also interested in doing the same thing with file contents (one would use
in the working tree).

If this is not possible, then how does github, gitlab, bitbucket, etc. handle file listing/viewing internally?
git checkout


Individually git show <ref>:<path

You could have googled that.