diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 008816ea..dd4a1794 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -372,7 +372,6 @@ jobs: name: Upload release needs: test runs-on: ubuntu-latest - if: startsWith(github.ref, 'refs/tags/v') environment: name: pypi @@ -392,6 +391,13 @@ jobs: - name: Publish PyPI package uses: pypa/gh-action-pypi-publish@release/v1 + if: startsWith(github.ref, 'refs/tags/v') + + - name: Publish TestPyPI package + uses: pypa/gh-action-pypi-publish@release/v1 + if: github.ref == 'refs/heads/test-release' + with: + repository-url: https://test.pypi.org/legacy/ - name: Create GitHub Release uses: softprops/action-gh-release@v2