From 303ba76d1f5ed30c51d3aedae5f452c497bbbed4 Mon Sep 17 00:00:00 2001 From: Arthur Hussey Date: Tue, 10 Sep 2024 14:28:21 +0100 Subject: [PATCH] used tag name not release name --- .github/workflows/publish.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c457cb3..344e21f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -13,11 +13,12 @@ jobs: strategy: matrix: python-version: ["3.9", "3.10", "3.11", "3.12"] + if: startsWith(github.ref, 'refs/tags/') steps: - uses: actions/checkout@v4 - name: Update version run: | - echo "__version__ = \"${{ github.event.release.name }}\"" > orb_models/__init__.py + echo "__version__ = \"${{ github.event.release.tag_name }}\"" > orb_models/__init__.py - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 with: @@ -48,7 +49,7 @@ jobs: cache-dependency-path: pyproject.toml - name: Update version run: | - echo "__version__ = \"${{ github.event.release.name }}\"" > orb_models/__init__.py + echo "__version__ = \"${{ github.event.release.tag_name }}\"" > orb_models/__init__.py - name: Install dependencies run: | pip install setuptools wheel build