We're using the GitHub api to see what's different between branches - but that doesn't actually show the changes between files in the branches. What it shows is what was changed in the commits being merged up.
If those changes are made in the 5 branch, and then made against in the 5.0 branch and merged up, this action will show us that there are changes, and could fail if those changes are made in composer.jsoneven though nothing will change in the merge-up.
Acceptance criteria
When checking if merge-up is allowed to happen automatically, based on the changes being merged up, git is used directly to check what will actually be changed, not what GitHub's API tells us.
Possibly the most reliable way to check this is using git merge --no-ff --no-commit and then checking staged files
We still merge up if there are commits that need to be merged up, even if no actual code change will be made
We're using the GitHub api to see what's different between branches - but that doesn't actually show the changes between files in the branches. What it shows is what was changed in the commits being merged up.
If those changes are made in the
5
branch, and then made against in the5.0
branch and merged up, this action will show us that there are changes, and could fail if those changes are made incomposer.json
even though nothing will change in the merge-up.Acceptance criteria
git merge --no-ff --no-commit
and then checking staged filesPRs