Objects are stored in <repository>/.git/objects in subfolders matching the first two chars of the sha.
fc1da6e8f is therefore the file: .git/objects/fc/1da6e8f.
git cat-file inflates and shows the content of what ever ref you pass it.
-p asks cat-file to pretty-print the content of an object.
git ls-tree master . inflates and lists the content of a folder.
- Use
git logto find the sha of a commit - Locate the file in the
.gitfolder - What is in the file?
- Use
git cat-file -p <sha>to inflate and view the content. - Use
git cat-fileto look at the tree referenced in your commit - Use
git cat-fileto look at the parent commit - Do these commands work in the
.gitfolder? Do you have to be in there? - Compare
cat-filelooking at a tree object to usingls-treeon a commit - How does it look on an older commit compared to what you have in
HEAD?