0

I need list of commits made by specific author when project is developed using pair programing approach.

Basically pivotal's script is used to define a pair:

git pair uo ut

Than commits have this kind of author:

User One & User Two <pair+One+Two@company.com>

There is not constant pairs. Every day different pairs are made and I need list of commits made by one specific user during some period (some crapy requirement from legal department related to copyrights).

Code-Apprentice
  • 81,660
  • 23
  • 145
  • 268
Marek R
  • 32,568
  • 6
  • 55
  • 140
  • Possible duplicate of [How can I view a git log of just one user's commits?](https://stackoverflow.com/questions/4259996/how-can-i-view-a-git-log-of-just-one-users-commits) – phd Jan 23 '18 at 23:50

2 Answers2

2

The simplest method is to take all the authors, grep for your author, and then run git log searching for the full author's name (i.e. the pairs in which your author worked). Something along the lines of:

git log --format='%aN' | grep "some name" | xargs -Xmyauth git log --author=myauth 

Feel free to use a --pretty in the git log to make the output as you see fit.

Paul92
  • 8,827
  • 1
  • 23
  • 37
1

This functionality is not available in "pure" git as far as I know. If you are using git pair-commit then you will be able to see some of the commits made by a specific user in the normal git log.

Code-Apprentice
  • 81,660
  • 23
  • 145
  • 268