Skip to content

Commit ea9fa4e

Browse files
committed
Restore upload_pypi job in build_deploy workflow with necessary steps for artifact handling and publishing
1 parent e445837 commit ea9fa4e

File tree

1 file changed

+17
-18
lines changed

1 file changed

+17
-18
lines changed

.github/workflows/build_deploy.yml

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
name: Build and upload to PyPI
22

33
on:
4-
workflow_dispatch:
54
release:
65
types:
76
- published
@@ -55,21 +54,21 @@ jobs:
5554
name: cibw-sdist
5655
path: dist/*.tar.gz
5756

58-
# upload_pypi:
59-
# needs: [build_wheels, build_sdist]
60-
# runs-on: ubuntu-latest
61-
# environment: pypi
62-
# permissions:
63-
# id-token: write
64-
# if: github.event_name == 'release' && github.event.action == 'published'
65-
# steps:
66-
# - uses: actions/download-artifact@v4
67-
# with:
68-
# # unpacks all CIBW artifacts into dist/
69-
# pattern: cibw-*
70-
# path: dist
71-
# merge-multiple: true
57+
upload_pypi:
58+
needs: [build_wheels, build_sdist]
59+
runs-on: ubuntu-latest
60+
environment: pypi
61+
permissions:
62+
id-token: write
63+
if: github.event_name == 'release' && github.event.action == 'published'
64+
steps:
65+
- uses: actions/download-artifact@v4
66+
with:
67+
# unpacks all CIBW artifacts into dist/
68+
pattern: cibw-*
69+
path: dist
70+
merge-multiple: true
7271

73-
# - uses: pypa/gh-action-pypi-publish@release/v1
74-
# with:
75-
# password: ${{ secrets.PYPI_API_TOKEN }}
72+
- uses: pypa/gh-action-pypi-publish@release/v1
73+
with:
74+
password: ${{ secrets.PYPI_API_TOKEN }}

0 commit comments

Comments
 (0)