File tree Expand file tree Collapse file tree 1 file changed +37
-0
lines changed
Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Original file line number Diff line number Diff line change 1+ # This workflow uses actions that are not certified by GitHub.
2+ # They are provided by a third-party and are governed by
3+ # separate terms of service, privacy policy, and support
4+ # documentation.
5+ name : Dependabot auto-approve and auto-merge
6+
7+ on : pull_request
8+
9+ permissions :
10+ contents : write
11+ pull-requests : write
12+
13+ jobs :
14+ dependabot :
15+ runs-on : ubuntu-latest
16+ if : github.event.pull_request.user.login == 'dependabot[bot]' && github.repository == 'IntelliTect/try'
17+ steps :
18+ - name : Dependabot metadata
19+ id : metadata
20+ uses : dependabot/fetch-metadata@v2
21+ with :
22+ github-token : " ${{ secrets.GITHUB_TOKEN }}"
23+
24+ - name : Approve PR
25+ run : gh pr review --approve "$PR_URL"
26+ env :
27+ PR_URL : ${{ github.event.pull_request.html_url }}
28+ GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
29+
30+ - name : Enable auto-merge for patch and minor updates
31+ if : |
32+ steps.metadata.outputs.update-type == 'version-update:semver-patch' ||
33+ steps.metadata.outputs.update-type == 'version-update:semver-minor'
34+ run : gh pr merge --auto --squash "$PR_URL"
35+ env :
36+ PR_URL : ${{ github.event.pull_request.html_url }}
37+ GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments