From 5a6375ad885d76ac82df3140534b2f6d03fe9649 Mon Sep 17 00:00:00 2001 From: Marlon Saglia Date: Fri, 30 Aug 2024 14:33:12 +0200 Subject: [PATCH] feat(ci): update publish-cli.yml to handle tag versions Modify the publish-cli.yml workflow to correctly extract the version from the git tag, removing the leading "v" prefix. This ensures the correct version is used for the published artifact. --- .github/workflows/publish-cli.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish-cli.yml b/.github/workflows/publish-cli.yml index 3487e203aa1a..7af00aeced2b 100644 --- a/.github/workflows/publish-cli.yml +++ b/.github/workflows/publish-cli.yml @@ -29,7 +29,8 @@ jobs: id: meta run: | if [[ "${{ github.event_name }}" == "push" && "${{ startswith(github.ref, 'refs/tags/v') }}" == "true" ]]; then - BUILD_VERSION="${{ github.ref_name }}" + # Remove the "v" prefix from the tag. + BUILD_VERSION="${GITHUB_REF_NAME#v}" else BUILD_VERSION="0.0.0-dev_${{ github.run_number }}" fi