-
Notifications
You must be signed in to change notification settings - Fork 7
How to release
- make sure the right version is set in setup.py and doc's conf.py
- Make sure "What's new" file was updated and included in Docs
- Check docs
- Build docs locally
sphinx-build -b html path/to/doc/ output/path/
- Remove errors and warnings as far as possible
- Build docs locally
-
Create pull request (to
master
) -
Merge or let someone else merge it
-
Check dist with twine:
twine check dist/*
and fix all errors -
Create a release tag on
master
-
Release via PyPI (if you don't have permissions for this repo, ask @gplssm, @nesnoj) This link may be helpful.
-
Pull master to get the release tag (If you do not see the tag type 'git fetch'.)
-
Make sure you have the latest versions of setuptools and wheel installed:
python3 -m pip install --user --upgrade setuptools wheel twine
-
Now run this command from the same directory where setup.py is located:
python3 setup.py sdist bdist_wheel
-
README - Last check on README file because it will be the first page on PyPi
python3 -m twine check dist/*
If errors occur fix them now and check again. It is NOT possible to fix them after the release.
-
Run Twine to upload all of the archives under dist to TestPyPI (you need to register at TestPyPI first)
twine upload --repository-url https://test.pypi.org/legacy/ dist/*
-
Before uploading to PyPI you can now test the uploaded package by installing it from TestPyPI and check if everything works correctly (e.g. run an example).
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple ding0
-
If everything works as expected you can now upload the new ding0 version to PyPI.
twine upload dist/*
-
-
List package versions in Installed-packages by using
conda list --export
- bump version to the next one (in dev branch) specified in
setup.py
- Add "What's new" file for next version: file itself and include statement in
whatsnews.rst
- Generate a new dataset
- Add Zenodo badges to GitHub: source code and data