Skip to content

Commit

Permalink
fix check package version step (multiple 'v' issue)
Browse files Browse the repository at this point in the history
  • Loading branch information
yogh333 committed Dec 7, 2023
1 parent f99aa68 commit b223f1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,11 @@ jobs:
id: check-version
run: |
PACKAGE_NAME="${{ steps.determine-package.outputs.package }}"
TAG_VERSION=$(echo "${{ github.ref }}" | cut -d 'v' -f 2)
TAG_VERSION=$(echo "${{ github.ref }}" | rev | cut -d 'v' -f 1 | rev)
MANIFEST_VERSION=$(cargo metadata --format-version=1 --no-deps | jq -r --arg PACKAGE_NAME "$PACKAGE_NAME" '.packages[] | select(.name == $PACKAGE_NAME) | .version')
if [ "$TAG_VERSION" != "$MANIFEST_VERSION" ]; then
echo "Package version in manifest does not match tag version."
echo "Package version in manifest $MANIFEST_VERSION does not match tag version $TAG_VERSION."
exit 1
else
echo "Package version in manifest matches tag version."
Expand Down

0 comments on commit b223f1c

Please sign in to comment.