File tree Expand file tree Collapse file tree 2 files changed +52
-8
lines changed Expand file tree Collapse file tree 2 files changed +52
-8
lines changed Original file line number Diff line number Diff line change 1+ # Moving back to npm for package management rather than bun
2+ # because wow dependabot is so broken for it 😭
3+ # TODO: Labels on package updates after project restructure
4+
15version : 2
26updates :
3- - package-ecosystem : " bun "
7+ - package-ecosystem : " npm "
48 directory : " /"
59 schedule :
610 interval : " weekly"
7- assignees :
8- - " GalvinPython"
911 target-branch : " dev"
1012
11- - package-ecosystem : " bun "
13+ - package-ecosystem : " npm "
1214 directory : " /web"
1315 schedule :
1416 interval : " weekly"
15- assignees :
16- - " GalvinPython"
1717 target-branch : " dev"
18- labels : ["dependencies", "javascript", "component: web"]
1918
2019 - package-ecosystem : " cargo"
2120 directory : " /api"
2221 schedule :
23- interval : " weekly"
22+ interval : " weekly"
23+ target-branch : " dev"
Original file line number Diff line number Diff line change 1+ name : Update bun.lock
2+
3+ on :
4+ pull_request :
5+ branches : [main, dev]
6+
7+ permissions :
8+ contents : write
9+
10+ jobs :
11+ update-bun-lock :
12+ name : " Update bun.lock"
13+ runs-on : ubuntu-latest
14+ if : github.actor == 'dependabot[bot]'
15+ steps :
16+ - name : Set up Bun
17+ uses : oven-sh/setup-bun@v2
18+
19+ - name : Check out repository
20+ uses : actions/checkout@v4
21+
22+ - name : Install dependencies with Bun
23+ run : bun install
24+
25+ - name : Check for changes
26+ id : git_status
27+ run : |
28+ git add bun.lock
29+ if [ -z "$(git status --porcelain)" ]; then
30+ echo "No changes to bun.lock"
31+ echo "changes_detected=false" >> "$GITHUB_OUTPUT"
32+ else
33+ echo "Changes detected to bun.lock"
34+ echo "changes_detected=true" >> "$GITHUB_OUTPUT"
35+ fi
36+
37+ - name : Commit and push changes to bun.lock
38+ if : steps.git_status.outputs.changes_detected == 'true'
39+ run : |
40+ git config --global user.name 'github-actions[bot]'
41+ git config --global user.email 'github-actions[bot]@users.noreply.github.com'
42+ git commit -m "Update bun.lock (via GitHub Actions)"
43+ git pull --rebase origin ${{ github.head_ref }}
44+ git push origin ${{ github.head_ref }}
You can’t perform that action at this time.
0 commit comments