Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CI: add automatic publication to pypi.org and test.pypi.org
We want to reduce the potential for human error in our publication process and also streamline the process for everyone with the permission to create tags in the repository. The CI job runs for new commits pushed to the master branch and newly pushed tags, as long as the PUBLISH_PYPI GitHub Action variable is set to "true". This is to prevent CI runs on forked repository from failing because they are not allowed to publish on pypi.org and test.pypi.org. A fork that wants to use the publish logic just has to set the PUBLISH_PYPI variable for their repository. The job does not check out the git repository (hence why it does not use the existing publication logic in the Makefile) and instead downloads the artifacts generated by the build job. All builds are uploaded to test.pypi.org (so they can be tested via pip install) and tagged releases are uploaded to pypi.org as well. Also remove the upload helpers from the Makefile to make it clear that they are replaced by the automated process. Signed-off-by: Leonard Göhrs <[email protected]>
- Loading branch information