Is there a way using git to find out which developers' code was changed by a particular commit?
The process would look something like:
Take a commit SHA, get each changed line in the parent commit git diff SHA^!
, group them by the author of the line (git blame
) and then order them by number of lines and list it out like
Commit SHA### updated code written by the following developers:
Jane Smythe (23 lines)
Rickard Strauss (8 lines)
I am thinking of using this to print to the console when committing (the following devs code were modified, make sure to tag them in your PR), it could even be potentially integrated with Bitbucket/Git to automatically tag devs whose code is being changed or email them etc etc.
I found this gist using python that appears to do something similar, but is going into a separate language other than bash/git necessary for this?