Skip to content

Commit 3d9975c

Browse files
committed
release plz: dry-run in ci
1 parent 6bce6fe commit 3d9975c

File tree

1 file changed

+16
-14
lines changed

1 file changed

+16
-14
lines changed

.github/workflows/rust-ci.yml

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -93,27 +93,29 @@ jobs:
9393
submodules: true
9494
- uses: EmbarkStudios/cargo-deny-action@v2
9595

96-
publish-check:
97-
name: Publish Check
98-
runs-on: ubuntu-22.04
96+
release-plz-dry-run:
97+
name: Release-plz dry-run
98+
runs-on: ubuntu-latest
99+
permissions: {}
99100
steps:
100-
- uses: actions/checkout@v4
101+
- uses: actions/checkout@v6
101102
with:
103+
ref: ${{ github.head_ref }}
104+
fetch-depth: 0
105+
persist-credentials: false
102106
submodules: true
103-
- uses: cargo-bins/cargo-binstall@main
104-
- run: cargo binstall cargo-release
105-
- run: cargo fetch --locked
106-
# cargo release in workspace root doesn't actually run `publish check` on any crate, do so manually
107-
- name: cargo publish check spirv-tools-sys
108-
run: cargo release patch --allow-branch=* --manifest-path spirv-tools-sys/Cargo.toml
109-
- name: cargo publish check spirv-tools
110-
run: cargo release patch --allow-branch=* --manifest-path spirv-tools/Cargo.toml
107+
- name: Run release-plz
108+
uses: release-plz/action@v0.5
109+
with:
110+
dry_run: true
111+
env:
112+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
111113

112114
# This allows us to have a single job we can branch protect on, rather than needing
113115
# to update the branch protection rules when the test matrix changes
114116
test_success:
115117
runs-on: ubuntu-24.04
116-
needs: [lint, test, deny-check, publish-check]
118+
needs: [lint, test, deny-check, release-plz-dry-run]
117119
# Hack for buggy GitHub Actions behavior with skipped checks: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks
118120
if: ${{ always() }}
119121
steps:
@@ -123,7 +125,7 @@ jobs:
123125
[[ "${{ needs.lint.result }}" == "success" ]] || exit 1
124126
[[ "${{ needs.test.result }}" == "success" ]] || exit 1
125127
[[ "${{ needs.deny-check.result }}" == "success" ]] || exit 1
126-
[[ "${{ needs.publish-check.result }}" == "success" ]] || exit 1
128+
[[ "${{ needs.release-plz-dry-run.result }}" == "success" ]] || exit 1
127129
128130
defaults:
129131
run:

0 commit comments

Comments
 (0)