I am trying to count the commits by each author but like to exclude commits whos messages begin with the word TEST.. for example.
I am currently doing the following to get the list.
git shortlog -s -n --all
This brings back my counts but drilling into each authors commits shows a lot which start with TEST.. I would like to get the count without these commits included.. is this possible?
The following one-liner will work. I am using Git Bash, which is up to version 1.9.4.
If you have a later version that accepts the
--invert-grep
option you can probably use the following. (I noticed that shortlog seems to take all the same arguments as log, but it is undocumented.) I cannot test this though.