-
Notifications
You must be signed in to change notification settings - Fork 24
40 lines (34 loc) · 1011 Bytes
/
release.yml
File metadata and controls
40 lines (34 loc) · 1011 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
name: Release
on:
push:
branches: [master]
permissions:
contents: write
pull-requests: write
jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.RELEASE_PLEASE_TOKEN }}
- uses: actions/checkout@v4
if: steps.release.outputs.pr
with:
ref: ${{ fromJson(steps.release.outputs.pr).headBranchName }}
- uses: dtolnay/rust-toolchain@stable
if: steps.release.outputs.pr
- name: Update Cargo.lock
if: steps.release.outputs.pr
run: |
cargo fetch
if git diff --quiet Cargo.lock; then
echo "Cargo.lock already up to date"
exit 0
fi
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add Cargo.lock
git commit -m "chore: update Cargo.lock"
git push