python -m pip install setuptools wheel twine
Update the version in the setup.py file here.
setup.py
Creating a new GitHub release will trigger the Upload Python Package GitHub action that will create and upload the package automatically.
Upload Python Package
Note:: don't save the release as a draft, but publish it directly otherwise the GitHub action will not be triggered.
python setup.py bdist_wheel python -m twine upload --repository pypi dist/* #python -m twine upload --repository pypitest dist/*
To upload you have to make sure that C:\Users\UserName\.pypirc / ~/.pypirc contains:
C:\Users\UserName\.pypirc
~/.pypirc
[distutils] index-servers = pypi pypitest [pypi] username: Cyberbotics password: password [pypitest] repository: https://test.pypi.org/legacy/ username: Cyberbotics password: password