Skip to content

Commit da33fd9

Browse files
authored
Add auto-merge workflow for trusted contributors (#121)
1 parent 71da251 commit da33fd9

1 file changed

Lines changed: 20 additions & 0 deletions

File tree

.github/workflows/auto-merge.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: Auto-merge
2+
on:
3+
pull_request_target:
4+
types: [opened, synchronize, reopened]
5+
6+
permissions:
7+
contents: write
8+
pull-requests: write
9+
10+
jobs:
11+
auto-merge:
12+
name: 🤝 Auto-merge
13+
runs-on: ubuntu-latest
14+
if: github.actor == 'gaborbernat' || github.actor == 'dependabot[bot]' || github.actor == 'pre-commit-ci[bot]' || github.actor == 'github-actions[bot]'
15+
steps:
16+
- name: 🔀 Enable auto-merge
17+
run: gh pr merge --auto --squash "$PR_URL"
18+
env:
19+
PR_URL: ${{ github.event.pull_request.html_url }}
20+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)