Skip to content

Latest commit

 

History

History
48 lines (33 loc) · 1002 Bytes

File metadata and controls

48 lines (33 loc) · 1002 Bytes

Publishing to PyPI

1. Prepare an account and API token

  1. Register and sign in at https://pypi.org.
  2. In Account settings -> API tokens, create a token.
  3. For the first release it is recommended to publish to TestPyPI first: https://test.pypi.org

2. Build the package

python -m pip install -U build twine
python -m build

Artifacts are produced under dist/, including .whl and .tar.gz files.

3. Check package metadata

python -m twine check dist/*

4. Upload to TestPyPI (recommended first)

python -m twine upload --repository testpypi dist/*

Verify the install:

python -m pip install -i https://test.pypi.org/simple/ mumu-python-api-wlkjyy

5. Upload to production PyPI

python -m twine upload dist/*

6. Optional: use environment variables to avoid prompting

$env:TWINE_USERNAME="__token__"
$env:TWINE_PASSWORD="pypi-xxxx"
python -m twine upload dist/*