check number of commits git code example
Example 1: find total commits in git
git rev-list --all --count
Example 2: find total commit in git by specific user
git shortlog -s -n --all --no-merges
git rev-list --all --count
git shortlog -s -n --all --no-merges