Repository navigation
60 lines (49 loc) · 1.97 KB
/
Copy pathrelease.yml
File metadata and controls
60 lines (49 loc) · 1.97 KB
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Release
on:
push:
branches: [main]
permissions:
contents: write
pull-requests: write
id-token: write
jobs:
release:
name: Release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
persist-credentials: true
- name: Install Rust
uses: actions-rust-lang/setup-rust-toolchain@ecabd13d1c56bd1345c230e542e9144811ad706f # v2.0.0
- name: Authenticate with crates.io
uses: rust-lang/crates-io-auth-action@c6f97d42243bad5fab37ca0427f495c86d5b1a18 # v1.0.5
id: auth
- name: release-plz
uses: MarcoIeni/release-plz-action@b8d6b54b02889ff2ae2bb82e8b57c3a8fc1683a5 # v0.5.139
id: release-plz
env:
GITHUB_TOKEN: ${{ github.token }}
CARGO_REGISTRY_TOKEN: ${{ steps.auth.outputs.token }}
- name: Install Nix
if: ${{ steps.release-plz.outputs.prs_created == 'true' || steps.release-plz.outputs.releases_created == 'true' }}
uses: nixbuild/nix-quick-install-action@9f63be77f412a248c9d9a65a4c82cf066cdf8f0c # v35
- name: Enter Nix devshell
if: ${{ steps.release-plz.outputs.prs_created == 'true' || steps.release-plz.outputs.releases_created == 'true' }}
uses: nicknovitski/nix-develop@9be7cfb4b10451d3390a75dc18ad0465bed4932a # v1.2.1
with:
arguments: .#ci-release
- name: Bump changelog versions
if: ${{ steps.release-plz.outputs.prs_created == 'true' }}
env:
GH_TOKEN: ${{ github.token }}
RELEASE_PLZ_PR_JSON: ${{ steps.release-plz.outputs.pr }}
run: x52-bump-changelogs
- name: Update release notes
if: ${{ steps.release-plz.outputs.releases_created == 'true' }}
env:
GH_TOKEN: ${{ github.token }}
RELEASE_PLZ_RELEASES_JSON: ${{ steps.release-plz.outputs.releases }}
run: x52-update-release-notes --then-undraft