diff --git a/.github/workflows/pypi.yml b/.github/workflows/pypi.yml index 5040efa..6554a62 100644 --- a/.github/workflows/pypi.yml +++ b/.github/workflows/pypi.yml @@ -70,18 +70,21 @@ jobs: upload_pypi: needs: [build_wheels, build_sdist] runs-on: ubuntu-latest - # upload to PyPI on every tag starting with 'v' - # if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v') - # alternatively, to publish when a GitHub Release is created, use the following rule: + environment: pypi + # upload to PyPI on every tag starting with 'v' + # if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v') + # alternatively, to publish when a GitHub Release is created, use the following rule: if: github.event_name == 'release' && github.event.action == 'published' steps: - - uses: actions/download-artifact@v4 - with: - # unpacks all CIBW artifacts into dist/ - pattern: cibw-* + - name: Download artifacts + uses: actions/download-artifact@v4 + with: + # unpacks all CIBW artifacts into dist/ + pattern: cibw-* path: dist merge-multiple: true - - uses: pypa/gh-action-pypi-publish@release/v1 + - name: Upload release to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 with: user: __token__ password: ${{ secrets.pypitoken }}