Skip to content

Commit 5581e34

Browse files
committed
Only try to upload wheel on release events
This will allow us to test the workflow manually to fix build issues without actually making a release
1 parent f03bec6 commit 5581e34

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

.github/workflows/release-to-pypi.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ jobs:
3636
uses: pypa/[email protected]
3737

3838
- name: Check and upload wheels
39+
if: ${{ github.event_name == 'release' }}
3940
env:
4041
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
4142
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
@@ -63,6 +64,7 @@ jobs:
6364
run: python -m build --sdist
6465

6566
- name: Publish sdist to PyPI
67+
if: ${{ github.event_name == 'release' }}
6668
env:
6769
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
6870
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}

0 commit comments

Comments
 (0)