Return commit count for a ref.
Section: Search, Filter, and Select Commits
Count commits on branch
bash
bash
git rev-list --count HEADLearn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Search, Filter, and Select Commits