Skip to content

Commit 47f9caa

Browse files
committed
Make pypi deployment dependent on test-pypi deployment
This commit changes the deployment to PyPI to be dependent on successful deployment to Test PyPI. Without this we would have to manually check that the deployment to Test PyPI succeeded before deploying to PyPI, and there's really no point in making that a manual process. (Or, a person could just deploy to PyPI directly without even waiting for the Test PyPI deployment to succeed and in that case there's no point in even deploying to Test PyPI first.) I was inspired to do this by looking at the release workflow for some other project, but I forget which one it was.
1 parent 02a6df1 commit 47f9caa

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/release.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ jobs:
2929
publish-to-test-pypi:
3030
name: Publish packages to Test PyPI
3131
runs-on: ubuntu-latest
32-
needs: [build]
32+
needs:
33+
- build
3334
environment: test-pypi
3435
permissions:
3536
# this permission is mandatory for trusted publishing
@@ -47,7 +48,9 @@ jobs:
4748
publish-to-pypi:
4849
name: Publish packages to PyPI
4950
runs-on: ubuntu-latest
50-
needs: [build]
51+
needs:
52+
- build
53+
- publish-to-test-pypi
5154
environment: pypi
5255
permissions:
5356
# this permission is mandatory for trusted publishing

0 commit comments

Comments
 (0)