2

I've seen this question, but it doesn't really address what I need. I know what file I'm interested in; I need to get a list of commits where I've modified that particular file. Is this possible? I work on a team of 6 devs, so there are literally thousands of commits in our repo.

Community
  • 1
  • 1
EmmyS
  • 11,892
  • 48
  • 101
  • 156
  • Duplicate of [How can I view a git log of just one user's commits?](http://stackoverflow.com/questions/4259996/how-can-i-view-a-git-log-of-just-one-users-commits) –  May 23 '14 at 18:40
  • Not really; my question specifically required the file name to be included as an option, which the question your referring to did not answer. – EmmyS May 23 '14 at 19:23
  • I don't consider that to be a significant difference, especially when [the documentation states that you can restrict the log to an individual path](https://www.kernel.org/pub/software/scm/git/docs/git-log.html), but if other people disagree, they can simply vote to reopen the question if it's closed. –  May 23 '14 at 19:25

1 Answers1

3

This is actually really simple, just combine --author with the path of the file that you are interested in.

git log --author="My Name" -- <this_file>
CB Bailey
  • 755,051
  • 104
  • 632
  • 656