release-pypi.sh: add --test flag for dry-run uploads to TestPyPI

Passes --repository testpypi to twine upload, prints the target index
before the confirmation prompt, and documents the new flag in the README
along with a link to the TestPyPI guide.
This commit is contained in:
Jacob Alexander
2026-05-30 09:48:38 -07:00
parent 55e056e990
commit fb3408f81d
2 changed files with 31 additions and 7 deletions

View File

@@ -120,6 +120,13 @@ scripts/release-pypi.sh v2.2.1
# Or, target a specific Actions run id:
scripts/release-pypi.sh 1234567890
# Dry run: upload to TestPyPI (https://test.pypi.org) instead of real PyPI.
# Useful for validating the release flow end-to-end before pushing to
# production. Requires a TestPyPI account + API token configured in
# ~/.pypirc under a [testpypi] section. See
# https://packaging.python.org/en/latest/guides/using-testpypi/ .
scripts/release-pypi.sh v2.2.1 --test
```
Requirements on the release machine: