Skip to content

Commit

Permalink
Add towncrier as a dev dependency and fix template
Browse files Browse the repository at this point in the history
Signed-off-by: Aurélien Bompard <[email protected]>
  • Loading branch information
abompard committed Jul 21, 2021
1 parent d2b8bfa commit 9caefe9
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 36 deletions.
2 changes: 1 addition & 1 deletion docs/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ When cutting a new release, follow these steps:
#. Run ``poetry install`` to update the version in the metadata
#. Add missing authors to the release notes fragments by changing to the ``news`` directory and
running the ``get-authors.py`` script, but check for duplicates and errors
#. Generate the release notes by running ``towncrier`` (in the base directory)
#. Generate the release notes by running ``poetry run towncrier`` (in the base directory)
#. Adjust the release notes in ``docs/release_notes.rst``.
#. Generate the docs with ``tox -e docs`` and check them in ``docs/_build/html``.
#. Commit the changes
Expand Down
4 changes: 3 additions & 1 deletion news/_template.rst.j2
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@
{%- endif -%}
{%- endmacro -%}

{{ top_line }}
{{ top_underline * ((top_line)|length)}}

Released on {{ versiondata.date }}.
This is a {major|feature|bugfix} release that adds [short summary].

{% for section, _ in sections.items() %}
{% set underline = underlines[0] %}{% if section %}{{section}}
{{ underline * section|length }}{% set underline = underlines[1] %}
Expand Down
71 changes: 37 additions & 34 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ isort = "^5.1.4"
rstcheck = "^3.3.1"
pre-commit = "^2.13.0"
safety = "^1.10.3"
towncrier = "^21.3.0"

[tool.poetry.extras]
deploy = ["gunicorn"]
Expand Down

0 comments on commit 9caefe9

Please sign in to comment.