Qaz Qaz - 1 month ago 6x
Git Question

Git branch files changed from command line

I understand that I can use

git diff master
to see how my feature branch is different from the master branch. I'm only interested in changes made by this particular branch, though, not changes on master. On GitHub, I can see the files changed under the "Files changed" tab of a pull request. How can I get the same list of files from the command line?


You can use the --name-only option to git diff:

$ git diff --name-only master...<feature branch>