Skip to content

Commit 9ba608c

Browse files
committed
Verifier workflow, either auto merge or approve
1 parent 894ef0a commit 9ba608c

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

.github/workflows/Verify.Redist.Update.yaml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
name: "Verify Redist Update"
1818
runs-on: ubuntu-latest
1919
env:
20-
ALLOW_AUTO_APPROVE_REDIST_PR: ${{ vars.ALLOW_AUTO_APPROVE_REDIST_PR }}
20+
ALLOW_AUTO_MERGE_REDIST_PR: ${{ vars.ALLOW_AUTO_MERGE_REDIST_PR }}
2121
permissions:
2222
pull-requests: write
2323
contents: read
@@ -52,7 +52,14 @@ jobs:
5252
fi
5353
5454
- name: Auto-approve PR
55-
if: success() && env.ALLOW_AUTO_APPROVE_REDIST_PR == 'true' && github.actor == 'sunnamed434'
55+
if: success() && env.ALLOW_AUTO_MERGE_REDIST_PR != 'true' && github.actor == 'sunnamed434'
5656
uses: hmarr/auto-approve-action@v4
5757
with:
5858
github-token: ${{ secrets.GITHUB_TOKEN }}
59+
60+
- name: Auto-merge PR
61+
if: success() && env.ALLOW_AUTO_MERGE_REDIST_PR == 'true' && github.actor == 'sunnamed434'
62+
uses: peter-evans/enable-pull-request-automerge@v3
63+
with:
64+
token: ${{ secrets.PAT }}
65+
merge-method: squash

0 commit comments

Comments
 (0)