Tags: #git Links: [[Get File Count for Git Repository]] [[Get List of Files for a Specific Commit in Git Repository]] # Get File Count for a Specific Commit in Git Repository Command: ``` git ls-tree -r --name-only SHA | wc -l ``` Replace `SHA` with the actual SHA of a commit. Example: ``` git ls-tree -r --name-only e75961e9c5f20520aca28346a327e9e847cfe92d | wc -l ```