diff --git a/.github/workflows/publish-docker.yml b/.github/workflows/publish-docker.yml index 1b70b3b..82b4914 100644 --- a/.github/workflows/publish-docker.yml +++ b/.github/workflows/publish-docker.yml @@ -44,7 +44,11 @@ jobs: git config user.email "actions@github.com" bump2version ${{ env.bump_type }} git push --follow-tags - echo "version=$(bump2version --dry-run --list | grep new_version | sed -r s,'^.*=',,)" >> $GITHUB_ENV + - name: Get New Version from pyproject.toml + id: extract_version + run: | + VERSION=$(sed -n 's/^version = "\(.*\)"/\1/p' pyproject.toml) + echo "VERSION=$VERSION" >> $GITHUB_ENV build_and_push: runs-on: ubuntu-latest @@ -68,5 +72,5 @@ jobs: with: context: . tags: | - ghcr.io/${{ env.repo_name }}:${{ env.version }} + ghcr.io/${{ env.repo_name }}:${{ env.VERSION }} ghcr.io/${{ env.repo_name }}:latest