File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -29,15 +29,17 @@ jobs:
2929 if : startsWith(github.ref, 'refs/tags/')
3030 shell : bash
3131 run : |
32- set -eou
33- version=$(grep '^version' Cargo.toml | awk -F' = ' '{print $2}' | tr -d '"')
34- version="v$version"
32+ set -eou pipefail
3533 tag='${{github.ref}}'
3634 tag="${tag#refs/tags/}"
37- if [ "$tag" != "$version" ]; then
38- echo "::error::Git tag doesn't match the Cargo version! ($tag != $version)"
39- exit 1
40- fi
35+ for file in */Cargo.toml; do
36+ version=$(grep '^version' $file | head -1 | awk -F' = ' '{print $2}' | tr -d '"')
37+ version="v$version"
38+ if [ "$tag" != "$version" ]; then
39+ echo "::error::Git tag doesn't match the Cargo version! ($tag != $version)"
40+ exit 1
41+ fi
42+ done
4143 - name : Setup Rust toolchain
4244 uses : dtolnay/rust-toolchain@stable
4345 with :
You can’t perform that action at this time.
0 commit comments