Skip to content

Commit 680d40c

Browse files
authored
Dependabot automerge (#12844)
Reduce toil. Will automerge patch and minor updates
1 parent 8f48aca commit 680d40c

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

.github/workflows/changelog.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ on:
1212
jobs:
1313
check:
1414
if: |
15+
github.event.pull_request.user.login != 'dependabot[bot]' &&
1516
!contains(github.event.pull_request.head.ref, 'changeset-release') &&
1617
!contains(github.event.pull_request.labels.*.name, '🤖Skip Changelog')
1718
runs-on: ubuntu-latest
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Dependabot Auto-merge
2+
on: pull_request_target
3+
4+
permissions:
5+
pull-requests: write
6+
contents: write
7+
8+
jobs:
9+
dependabot:
10+
runs-on: shopify-ubuntu-latest
11+
if: ${{ github.event.pull_request.user.login == 'dependabot[bot]' }}
12+
steps:
13+
- name: Dependabot metadata
14+
id: dependabot-metadata
15+
uses: dependabot/fetch-metadata@v2
16+
with:
17+
github-token: '${{ secrets.GITHUB_TOKEN }}'
18+
19+
- name: Approve and /shipit Dependabot PRs for patch and minor versions
20+
if: ${{ steps.dependabot-metadata.outputs.update-type != 'version-update:semver-major' }}
21+
run: gh pr merge --auto --merge "$PR_URL"
22+
env:
23+
PR_URL: ${{github.event.pull_request.html_url}}
24+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

0 commit comments

Comments
 (0)