diff --git a/.github/workflows/publish-release-to-pypi.yaml b/.github/workflows/publish-release-to-pypi.yaml index 3442b06..1e3e304 100644 --- a/.github/workflows/publish-release-to-pypi.yaml +++ b/.github/workflows/publish-release-to-pypi.yaml @@ -1,12 +1,10 @@ name: Publish Release package to Pypi.org on: - push: + release: branches: - - main jobs: build: - if: ${{ startsWith(github.ref, 'refs/tags/') }} # only publish to test.pypi.org on tagged commits from test branch environment: name: pypi url: https://pypi.org/p/dcnodatg # Replace with your PyPI project name @@ -32,7 +30,6 @@ jobs: name: python-package-distributions path: dist/ publish-to-pypi: - if: ${{ startsWith(github.ref, 'refs/tags/') }} # only publish to test.pypi.org on tagged commits from test branch name: >- Publish Python distribution to PyPI needs: @@ -52,7 +49,6 @@ jobs: - name: Publish distribution to PyPI uses: pypa/gh-action-pypi-publish@release/v1 github-release: - if: ${{ startsWith(github.ref, 'refs/tags/') }} # only publish to test.pypi.org on tagged commits from test branch environment: name: pypi url: https://pypi.org/p/dcnodatg # Replace with your PyPI project name