- Create virtual environment
python3 -m venv env
- Install build tools
env/bin/pip3 install build twine
- Create package
env/bin/python3 -m build
- Upload package to PyPi test
env/bin/python3 -m twine upload --repository-url https://test.pypi.org/legacy/ dist/*
- Install package from PyPi test
env/bin/pip3 install --index-url https://test.pypi.org/simple/ --no-deps example-pkg-your-username==<version>
- Upload package to PyPi
env/bin/python3 -m twine upload dist/*