List all files changed in a pull request in Git/GitHub - Stack Overflow
In general, you can list the files changed between any two commits with git diff --name-only
:
Show all changed files between two Git commits
(Edited based on clarification.)
The problem here seems to be determining the 'merge base'. If all branches originate with master, then you could do:
git --no-pager diff --name-only FETCH_HEAD $(git merge-base FETCH_HEAD master)
This will show you the changes between the point at which the FETCH_HEAD
was branched from master
to the current FETCH_HEAD
. I tested this locally, and the PR branches are cut from master
I believe it should work
Read full article from List all files changed in a pull request in Git/GitHub - Stack Overflow
No comments:
Post a Comment