We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5f8a869 commit c6a7f25Copy full SHA for c6a7f25
1 file changed
.github/workflows/force-push.yml
@@ -1,4 +1,4 @@
1
-name: Merge PR into main (prefer PR changes)
+name: Merge PR into main (force PR changes)
2
3
on:
4
workflow_dispatch:
@@ -7,7 +7,7 @@ permissions:
7
contents: write
8
9
jobs:
10
- merge-prefer-pr:
+ merge-force-pr:
11
runs-on: ubuntu-latest
12
steps:
13
- name: Checkout repository
@@ -37,9 +37,9 @@ jobs:
37
git config user.name "github-actions[bot]"
38
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
39
40
- - name: Merge PR branch into main
+ - name: Force main to PR branch
41
run: |
42
git fetch origin
43
- git checkout main
44
- git merge -s recursive -X theirs origin/${{ steps.check.outputs.branch }} || true
45
- git push origin main
+ git checkout ${{ steps.check.outputs.branch }}
+ git checkout -B main
+ git push origin main --force
0 commit comments