Skip to content

Commit bbd1ccf

Browse files
authored
Merge branch 'main' into dependabot/bundler/rubocop-1.86.1
2 parents f3147c9 + 5289418 commit bbd1ccf

2 files changed

Lines changed: 35 additions & 1 deletion

File tree

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
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+
dependabot:
12+
runs-on: "ubuntu-latest"
13+
if: "github.event.pull_request.user.login == 'dependabot[bot]'"
14+
15+
steps:
16+
- name: "Fetch Dependabot metadata"
17+
id: "metadata"
18+
uses: "dependabot/fetch-metadata@v2"
19+
with:
20+
github-token: "${{ secrets.GITHUB_TOKEN }}"
21+
22+
- name: "Approve Dependabot PR"
23+
if: "steps.metadata.outputs.update-type == 'version-update:semver-patch'"
24+
run: "gh pr review --approve \"$PR_URL\""
25+
env:
26+
PR_URL: "${{ github.event.pull_request.html_url }}"
27+
GH_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
28+
29+
- name: "Enable auto-merge"
30+
if: "steps.metadata.outputs.update-type == 'version-update:semver-patch'"
31+
run: "gh pr merge --auto --squash \"$PR_URL\""
32+
env:
33+
PR_URL: "${{ github.event.pull_request.html_url }}"
34+
GH_TOKEN: "${{ secrets.GITHUB_TOKEN }}"

.github/workflows/workflow-failure-notify.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ permissions:
55

66
on:
77
workflow_run:
8-
workflows: ["Lint and Test"]
8+
workflows: ["Lint and Test", "Dependabot auto-merge"]
99
types: [completed]
1010

1111
jobs:

0 commit comments

Comments
 (0)