I would like to build a script that pulls simple statistics from my repository. I would like to exclude merge commits and revert commits from those statistics.
There was a question asked 8 years ago about distinguishing between regular commit and merge commit:
Telling if a Git commit is a Merge/Revert commit
The answer is great when it comes to merge commit (i.e. the commit that has more than one parent) but there is no satisfactory answer for distinguishing if commit is a revert commit.
I'm looking at GitPython package and can't find anything on their documentation that would help.
Any help would be greatly appreciated.
Alternatively if there is something already out there (either script/library/product) that helps with git statistics (and excludes merge commits and revert commits) I would also accept such answer.