File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -86,24 +86,23 @@ jobs:
8686 name : cibw-sdist
8787 path : dist/*.tar.gz
8888
89- # upload_pypi:
90- # name: Publish to PyPI
91- # needs: [build_wheels, build_sdist]
92- # runs-on: ubuntu-latest
93- # environment:
94- # name: pypi
95- # permissions:
96- # id-token: write
97- # # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
98- # if: ${{ github.event_name == 'workflow_dispatch' || contains(github.event.head_commit.message, 'publish-pypi') }}
99- # steps:
100- # - uses: actions/download-artifact@v4
101- # with:
102- # pattern: cibw-*
103- # path: dist
104- # merge-multiple: true
89+ upload_pypi :
90+ name : Publish to PyPI
91+ needs : [build_wheels, build_sdist]
92+ runs-on : ubuntu-latest
93+ environment :
94+ name : pypi
95+ permissions :
96+ id-token : write
97+ if : github.event_name == 'release' && github.event.action == 'published'
98+ steps :
99+ - uses : actions/download-artifact@v4
100+ with :
101+ pattern : cibw-*
102+ path : dist
103+ merge-multiple : true
105104
106- # - uses: pypa/gh-action-pypi-publish@release/v1
105+ - uses : pypa/gh-action-pypi-publish@release/v1
107106
108107 # upload_test_pypi:
109108 # name: Publish to TestPyPI
You can’t perform that action at this time.
0 commit comments