From 4020ddd946d48c6a2a85f0ade7f7b42b642c1b70 Mon Sep 17 00:00:00 2001 From: mhdzumair Date: Wed, 6 Nov 2024 14:36:52 +0530 Subject: [PATCH] fix version extraction and reference handling --- .github/workflows/main.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 3684ab60..218e4a20 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -24,14 +24,12 @@ jobs: echo "Error: Failed to extract previous version from release body" exit 1 fi - VERSION="${GITHUB_REF#refs/tags/v}" echo "PREVIOUS_VERSION=${PREVIOUS_VERSION}" >> "$GITHUB_OUTPUT" - echo "VERSION=${VERSION}" >> "$GITHUB_OUTPUT" - name: Update version numbers if: "!github.event.release.prerelease" run: | - make update-version VERSION_NEW=${{ steps.extract_versions.outputs.VERSION }} + make update-version VERSION_NEW=${{ github.ref_name }} - name: Commit and push version updates if: "!github.event.release.prerelease" @@ -39,7 +37,7 @@ jobs: git config --local user.email "action@github.com" git config --local user.name "GitHub Action" git add -A - git commit -m "chore: update version to ${{ steps.extract_versions.outputs.VERSION }}" + git commit -m "chore: update version to ${{ github.ref_name }}" git push origin HEAD:main mediafusion_docker_build: