diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4fa5050..07b8e0f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,12 +1,13 @@ name: Publish Python distribution -on: push +on: + release: + types: [published] jobs: build: name: Build distribution runs-on: ubuntu-latest - if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes steps: - uses: actions/checkout@v4 @@ -30,7 +31,6 @@ jobs: publish-to-pypi: name: Publish Python distribution to PyPI - if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes needs: - build runs-on: ubuntu-latest