mirror of
https://github.com/dashpay/dash.git
synced 2024-12-24 19:42:46 +01:00
ci: check ff after merge into base branch for PRs
This commit is contained in:
parent
aaccc9ea51
commit
c76e398caa
9
.github/workflows/merge-check.yml
vendored
9
.github/workflows/merge-check.yml
vendored
@ -26,11 +26,14 @@ jobs:
|
|||||||
- name: Check merge --ff-only
|
- name: Check merge --ff-only
|
||||||
run: |
|
run: |
|
||||||
git fetch origin master:master
|
git fetch origin master:master
|
||||||
git checkout master
|
|
||||||
if [[ "${{ github.event_name }}" == "pull_request"* ]]; then
|
if [[ "${{ github.event_name }}" == "pull_request"* ]]; then
|
||||||
git fetch origin pull/${{ github.event.pull_request.number }}/head
|
git fetch origin {{ github.event.pull_request.base.ref }}:base_branch
|
||||||
git merge --ff-only ${{ github.event.pull_request.head.sha }}
|
git checkout base_branch
|
||||||
|
git pull origin pull/${{ github.event.pull_request.number }}/head
|
||||||
|
git checkout master
|
||||||
|
git merge --ff-only base_branch
|
||||||
else
|
else
|
||||||
|
git checkout master
|
||||||
git merge --ff-only ${{ github.sha }}
|
git merge --ff-only ${{ github.sha }}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user