-
-
Notifications
You must be signed in to change notification settings - Fork 199
Expand file tree
/
Copy pathpr-auto-approve-dependabot.yaml
More file actions
27 lines (23 loc) · 875 Bytes
/
pr-auto-approve-dependabot.yaml
File metadata and controls
27 lines (23 loc) · 875 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
name: Dependabot Auto-Merge hl2sdk
on: pull_request
permissions:
contents: write
pull-requests: write
jobs:
dependabot-auto-merge:
runs-on: ubuntu-latest
if: github.event.pull_request.user.login == 'dependabot[bot]' && github.repository == 'roflmuffin/CounterStrikeSharp'
steps:
- name: Fetch Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@08eff52bf64351f401fb50d4972fa95b9f2c2d1b
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
- name: Approve and auto-merge hl2sdk updates
if: contains(steps.metadata.outputs.dependency-names, 'libraries/hl2sdk-cs2')
run: |
gh pr review --approve "$PR_URL"
gh pr merge --auto --squash "$PR_URL"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}