|
| 1 | +# How to make a release |
| 2 | + |
| 3 | +`jupyterhub-python-repo-template` is a package available on [PyPI] and |
| 4 | +[conda-forge]. |
| 5 | + |
| 6 | +These are the instructions on how to make a release. |
| 7 | + |
| 8 | +## Pre-requisites |
| 9 | + |
| 10 | +- Push rights to this GitHub repository |
| 11 | + |
| 12 | +## Steps to make a release |
| 13 | + |
| 14 | +1. Create a PR updating `CHANGELOG.md` with [github-activity] and continue when |
| 15 | + its merged. For details about this, see the [team-compass documentation] |
| 16 | + about it. |
| 17 | + |
| 18 | + [team-compass documentation]: https://jupyterhub-team-compass.readthedocs.io/en/latest/practices/releases.html |
| 19 | + |
| 20 | +2. Checkout main and make sure it is up to date. |
| 21 | + |
| 22 | + ```shell |
| 23 | + git checkout main |
| 24 | + git fetch origin main |
| 25 | + git reset --hard origin/main |
| 26 | + ``` |
| 27 | + |
| 28 | +3. Update the version, make commits, and push a git tag with `tbump`. |
| 29 | + |
| 30 | + ```shell |
| 31 | + pip install tbump |
| 32 | + ``` |
| 33 | + |
| 34 | + `tbump` will ask for confirmation before doing anything. |
| 35 | + |
| 36 | + ```shell |
| 37 | + # Example versions to set: 1.0.0, 1.0.0b1 |
| 38 | + VERSION= |
| 39 | + tbump ${VERSION} |
| 40 | + ``` |
| 41 | + |
| 42 | + Following this, the [CI system] will build and publish a release. |
| 43 | + |
| 44 | +4. Reset the version back to dev, e.g. `1.0.1.dev` after releasing `1.0.0`. |
| 45 | + |
| 46 | + ```shell |
| 47 | + # Example version to set: 1.0.1.dev |
| 48 | + NEXT_VERSION= |
| 49 | + tbump --no-tag ${NEXT_VERSION}.dev |
| 50 | + ``` |
| 51 | + |
| 52 | +5. Following the release to PyPI, an automated PR should arrive within 24 hours |
| 53 | + to [conda-forge/jupyterhub-python-repo-template-feedstock] with instructions |
| 54 | + on releasing to conda-forge. You are welcome to volunteer doing this, but |
| 55 | + aren't required as part of making this release to PyPI. |
| 56 | + |
| 57 | +[github-activity]: https://github.com/executablebooks/github-activity |
| 58 | +[pypi]: https://pypi.org/project/jupyterhub-python-repo-template/ |
| 59 | +[conda-forge]: https://anaconda.org/conda-forge/jupyterhub-python-repo-template |
| 60 | +[conda-forge/jupyterhub-python-repo-template-feedstock]: https://github.com/conda-forge/jupyterhub-python-repo-template-feedstock |
| 61 | +[ci system]: https://github.com/jupyterhub/jupyterhub-python-repo-template/actions/workflows/release.yaml |
0 commit comments