Skip to content

Commit 838148a

Browse files
committed
chore: add dependabot auto merge workflow
1 parent edd4586 commit 838148a

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Dependabot Auto Merge
2+
3+
on:
4+
pull_request:
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 == 'dependabot[bot]'
15+
16+
steps:
17+
- name: Fetch Dependabot metadata
18+
id: metadata
19+
uses: dependabot/fetch-metadata@v2
20+
21+
- name: Auto merge patch and minor updates
22+
if: steps.metadata.outputs.update-type == 'version-update:semver-patch' || steps.metadata.outputs.update-type == 'version-update:semver-minor'
23+
run: gh pr merge --auto --squash "$PR_URL"
24+
env:
25+
PR_URL: ${{ github.event.pull_request.html_url }}
26+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)