Skip to content

Commit 564dca5

Browse files
authored
ci: try to fix Update Cargo.lock job (#615)
We need more permission. Also does some other minor cleanup and allows us to run the workflow manually, so I can make sure it works.
1 parent 76ed428 commit 564dca5

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

.github/workflows/lock_upd.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,27 @@
11
name: Update Cargo.lock
22

33
on:
4+
# Allow manually running the update
5+
workflow_dispatch:
6+
# Run every Sunday at 00:00 UTC
47
schedule:
5-
# Run every Sunday at 00:00 UTC
68
- cron: '0 0 * * 0'
79

10+
# We need permissions to commit code and open a pull request
811
permissions:
9-
contents: read
12+
contents: write
1013
pull-requests: write
1114

1215
jobs:
1316
update-cargo-lock:
1417
runs-on: ubuntu-latest
1518
steps:
1619
- uses: actions/checkout@v4
17-
- uses: dtolnay/rust-toolchain@master
18-
with:
19-
toolchain: stable
20+
- uses: dtolnay/rust-toolchain@stable
2021
- name: Update dependencies
2122
run: cargo update
2223
- name: Create Pull Request
2324
uses: peter-evans/create-pull-request@v7
24-
env:
25-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2625
with:
2726
title: "Update Cargo.lock"
2827
commit-message: "Update Cargo.lock"

0 commit comments

Comments
 (0)