Qaz Qaz - 1 year ago 121
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?

Answer Source

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

$ git diff --name-only master...<feature branch>
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download