Skip to content

Commit 5890fef

Browse files
committed
release-plz: setup release-plz with manually written changelog
1 parent 2a0aab4 commit 5890fef

File tree

4 files changed

+63
-0
lines changed

4 files changed

+63
-0
lines changed

.github/workflows/release-plz.yml

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Release-plz
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
10+
# Release unpublished packages.
11+
release-plz-release:
12+
name: Release-plz release
13+
if: ${{ github.repository_owner == 'rust-gpu' }}
14+
runs-on: ubuntu-latest
15+
permissions:
16+
contents: write
17+
pull-requests: read
18+
steps:
19+
- &checkout
20+
name: Checkout repository
21+
uses: actions/checkout@v6
22+
with:
23+
fetch-depth: 0
24+
persist-credentials: false
25+
submodules: true
26+
- &install-rust
27+
name: Install Rust toolchain
28+
uses: dtolnay/rust-toolchain@stable
29+
- name: Run release-plz
30+
uses: release-plz/action@v0.5
31+
with:
32+
command: release
33+
env:
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
35+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
36+
37+
# Create a PR with the new versions and changelog, preparing the next release.
38+
release-plz-pr:
39+
name: Release-plz PR
40+
if: ${{ github.repository_owner == 'rust-gpu' }}
41+
runs-on: ubuntu-latest
42+
permissions:
43+
contents: write
44+
pull-requests: write
45+
concurrency:
46+
group: release-plz-${{ github.ref }}
47+
cancel-in-progress: false
48+
steps:
49+
- *checkout
50+
- *install-rust
51+
- name: Run release-plz
52+
uses: release-plz/action@v0.5
53+
with:
54+
command: release-pr
55+
env:
56+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
57+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}

.release-plz.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[changelog]
2+
body = """
3+
## [{{ version }}]{%- if release_link -%}({{ release_link }}){% endif %} - {{ timestamp | date(format="%Y-%m-%d") }}\n
4+
"""

spirv-tools-sys/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# Changelog
2+
23
All notable changes to this project will be documented in this file.
34

45
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

spirv-tools/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# Changelog
2+
23
All notable changes to this project will be documented in this file.
34

45
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

0 commit comments

Comments
 (0)