| 1 |
# Releasing |
| 2 |
|
| 3 |
## Using `jupyter_releaser` |
| 4 |
|
| 5 |
The recommended way to make a release is to use [`jupyter_releaser`](https://jupyter-releaser.readthedocs.io/en/latest/get_started/making_release_from_repo.html). |
| 6 |
|
| 7 |
## Manual Release |
| 8 |
|
| 9 |
### Prerequisites |
| 10 |
|
| 11 |
- First check that the CHANGELOG.md is up to date for the next release version |
| 12 |
- Install packaging requirements: `pip install pipx` |
| 13 |
|
| 14 |
### Bump version |
| 15 |
|
| 16 |
- `export version=<NEW_VERSION>` |
| 17 |
- `pipx run hatch version ${version}` |
| 18 |
- `git tag -a ${version} -m {version}` |
| 19 |
|
| 20 |
### Push to PyPI |
| 21 |
|
| 22 |
```bash |
| 23 |
rm -rf dist/* |
| 24 |
rm -rf build/* |
| 25 |
pipx run build . |
| 26 |
pipx run twine check dist/* |
| 27 |
pipx run twine upload dist/* |
| 28 |
``` |
| 29 |
|
| 30 |
### Dev version |
| 31 |
|
| 32 |
- Bump the patch version and add the 'dev' tag back to the end of the version tuple using `pipx run hatch version <DEV_VERSION>` |
| 33 |
|
| 34 |
### Push to GitHub |
| 35 |
|
| 36 |
```bash |
| 37 |
git push upstream && git push upstream --tags |
| 38 |
``` |