Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,22 @@ jobs:
outputs:
VERSION: ${{ steps.extract_version.outputs.VERSION }}

check-version:
name: check version
runs-on: ubuntu-latest
needs: extract-version
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- name: Verify crate version matches tag
# Check that the Cargo version starts with the tag,
# so that Cargo version 1.4.8 can be matched against both v1.4.8 and v1.4.8-rc.1
run: |
tag="${{ needs.extract-version.outputs.VERSION }}"
tag=${tag#v}
cargo_ver=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[0].version')
[[ "$tag" == "$cargo_ver"* ]] || { echo "Tag $tag doesn’t match the Cargo version $cargo_ver"; exit 1; }

build:
name: build release
runs-on: ${{ matrix.configs.os }}
Expand Down
Loading