Skip to content

Commit f9dfef5

Browse files
committed
add release workflow to CONTRIBUTING.md
Both for the template and for the package. Inspired by and fixes #156.
1 parent 4c25c48 commit f9dfef5

2 files changed

Lines changed: 40 additions & 0 deletions

File tree

CONTRIBUTING.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,17 @@ The sections below outline the steps in each case.
3939
1. create the pull request, e.g. following the instructions [here](https://help.github.com/articles/creating-a-pull-request/).
4040

4141
In case you feel like you've made a valuable contribution, but you don't know how to write or run tests for it, or how to generate the documentation: don't let this discourage you from making the pull request; we can help you! Just go ahead and submit the pull request, but keep in mind that you might be asked to append additional commits to your pull request.
42+
43+
## You want to make a new release of the code base
44+
45+
To create a release you need write permission on the repository.
46+
47+
1. Check the author list in [`CITATION.cff`](CITATION.cff)
48+
1. Update the version number in setup.cfg and CITATION.cff
49+
1. Update the `CHANGELOG.md` to include changes made
50+
1. Go to the [GitHub release page](https://github.com/nlesc/python-template/releases)
51+
1. Press draft a new release button
52+
1. Fill version, title and description field
53+
1. Press the Publish Release button
54+
55+
Also a Zenodo entry will be made for the release with its own DOI.

{{cookiecutter.directory_name}}/CONTRIBUTING.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,29 @@ The sections below outline the steps in each case.
4040
1. create the pull request, e.g. following the instructions [here](https://help.github.com/articles/creating-a-pull-request/).
4141

4242
In case you feel like you've made a valuable contribution, but you don't know how to write or run tests for it, or how to generate the documentation: don't let this discourage you from making the pull request; we can help you! Just go ahead and submit the pull request, but keep in mind that you might be asked to append additional commits to your pull request.
43+
44+
## You want to make a new release of the code base
45+
46+
To create a release you need write permission on the repository.
47+
48+
1. Check the author list in [`CITATION.cff`](CITATION.cff)
49+
1. Bump the version using `bump-my-version bump <major|minor|patch>`. For example, `bump-my-version bump major` will increase major version numbers everywhere it's needed (code, meta, etc.) in the repo. Alternatively the version can be manually changed in {{ cookiecutter.package_name }}/__init__.py, pyproject.toml, CITATION.cff and docs/conf.py (and other places it was possibly added).
50+
1. Update the `CHANGELOG.md` to include changes made
51+
1. Go to the [GitHub release page]({{ cookiecutter.repository_url }}/releases)
52+
1. Press draft a new release button
53+
1. Fill version, title and description field
54+
1. Press the Publish Release button
55+
<!--
56+
For projects that automatically publish to PyPI using a release or publish workflow, something like the following could be useful to add (make sure to replace the names and links):
57+
58+
1. Wait until [PyPi publish workflow]({{ cookiecutter.repository_url }}/actions/workflows/publish.yml) has completed
59+
1. Verify new release is on [PyPi](https://pypi.org/project/matchms/#history)
60+
-->
61+
<!--
62+
For projects that also build conda packages, e.g. on conda-forge or Bioconda, something like the following could be useful to add (example taken from matchms, make sure to replace the names and links):
63+
64+
1. Wait until new release is also on Bioconda (https://anaconda.org/bioconda/{{ cookiecutter.package_name }}) via a automaticly created PR on [bioconda recipes repo](https://github.com/bioconda/bioconda-recipes/pulls?q=is%3Apr+is%3Aopen+{{ cookiecutter.package_name }})
65+
1. Test {{ cookiecutter.package_name }} from bioconda by manually running [Conda verify]({{ cookiecutter.repository_url }}/actions/workflows/conda_verify.yml) workflow
66+
-->
67+
68+
Also a Zenodo entry will be made for the release with its own DOI.

0 commit comments

Comments
 (0)