-
Notifications
You must be signed in to change notification settings - Fork 258
41 lines (34 loc) · 1020 Bytes
/
dependabot-auto-fix.yml
File metadata and controls
41 lines (34 loc) · 1020 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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Dependabot Go Autofix
on:
pull_request:
types: [opened, synchronize, reopened]
workflow_dispatch:
permissions:
contents: write
pull-requests: write
jobs:
tidy-and-verify:
if: github.actor == 'dependabot[bot]'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6.0.2
with:
ref: ${{ github.head_ref }}
- uses: actions/setup-go@v6.4.0
with:
go-version-file: ./go.mod
- name: Install just
uses: extractions/setup-just@v4
- name: Run dependency update
run: just deps
- name: Commit and push changes
run: |
if [ -n "$(git status --porcelain)" ]; then
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add -A
git commit -m "chore: run just deps after Dependabot update"
git push
else
echo "No changes to commit."
fi