I've been able to print the all the logs that contain a particular string in their commit messages using:
git log --grep=<string>
Is it possible to get a list of all the files affected in a similar way. viz. all the files that were affected by the commits that the previous command shows.
Based on Amber's post, a clearer output I was envisaging was something like this:
> git log -p --name-only --grep=<string>
a/b/c/d/e/f/a.java
a/b/c/d/e/f/b.java
a/b/c/d/e/c.java
a/b/c/f.java
a/b/c/d/e/f/s/t.java
As an aside, if there is a good place to start on learning git commands, please point me to it. Thanks.
Explanation on why this question is not a duplicate of other questions already asked: I don't want the commit content, just he files that were changed without duplicating the names of the files (if they were used in multiple commits).