Package: zestreleaser.towncrier
zestreleaser.towncrierThis callstowncrierwhen releasing a package withzest.releaser.towncrierupdates your history file (likeCHANGES.rst) based on news snippets.
This is for exampleused by pip.The plugin will calltowncrier--version<package version>--yes.
You can get a preview of the result yourself by callingtowncrier--version1.2.3--draft.Thetowncriercommand should be on yourPATH.
The plugin can also find it when it is in the same directory as thefullreleasescript (orprerelease/postrelease).InstallationInstallzestreleaser.towncrierwithpip:$ pip install zestreleaser.towncrierThen you can runfullreleaselike you would normally do when releasing a package.ContributeIssue Tracker:https://github.com/collective/zestreleaser.towncrier/issuesSource Code:https://github.com/collective/zestreleaser.towncrierSupportIf you are having problems, please let us know by filing anissue.LicenseThe project is licensed under the GPL.pyproject.tomlexampletowncrierneeds a configuredpyproject.tomlfile in the root of the package, next to thesetup.py.
For reference, here is the literalpyproject.tomlfile fromzestreleaser.towncrier:[tool.towncrier]
issue_format = "`Issue #{issue} <https://github.com/collective/zestreleaser.towncrier/issues/{issue}>`_"
filename = "CHANGES.rst"
directory = "news/"
title_format = "{version} ({project_date})"
# First underline is used for version/date header.
# Second underline is used for the type names (like 'Bug fixes:').
underlines = ["-", ""]

[[tool.towncrier.type]]
directory = "breaking"
name = "Breaking changes:"
showcontent = true

[[tool.towncrier.type]]
directory = "feature"
name = "New features:"
showcontent = true

[[tool.towncrier.type]]
directory = "bugfix"
name = "Bug fixes:"
showcontent = true

[tool.isort]
profile = "black"ContributorsMaurits van Rees,m.van.rees@zestsoftware.nlChangelog1.3.0 (2022-04-19)New features:Use thebuildsubcommand fortowncrierto build the changelog.
Fixes compatibility withtowncrier21.9.0 or later.
Requirestowncrier19.9.0 or later.
[mcflugen] (Issue #22)For parsing, usetomliwhen on Python 3,tomlon Python 2.
Same astowncrierdid until recently.
[maurits] (Issue #23)1.2.0 (2019-03-05)New features:Use ‘python -m towncrier’ when the script is not easily findable.
Still check the directory of the fullrelease script first.
No longer check the PATH.
[maurits] (Issue #17)Bug fixes:Do not run sanity checks or run draft during postrelease.  [maurits] (Issue #16)1.1.0 (2019-03-05)New features:Rerelease 1.0.3 as 1.1.0, as it contains new features. (Issue #9)1.0.3 (2019-03-05)New features:Report on sanity of newsfragments: do they have the correct extensions?
Is at least one found?
Show dry-run (draft) of what towncrier would do.
[maurits] (Issue #9)Handle multiple news entries per issue/type pair.  [maurits] (Issue #14)1.0.2 (2019-03-04)Bug fixes:Fixed finding towncrier when sys.argv is messed up.  [maurits] (Issue #6)1.0.1 (2019-02-20)Bug fixes:Tell bumpversion to not update the history. [maurits] (Issue #10)1.0.0 (2019-02-06)New features:Warn and ask when towncrier is wanted but not found. [maurits] (Issue #7)1.0.0b3 (2018-05-17)New features:Require towncrier 18.5.0 so we don’t need a package name in the config.
[maurits] (Issue #3)Bug fixes:First look fortowncriernext to thefull/prereleasescript. Then
fall back to looking on thePATH. [maurits] (Issue #4)1.0.0b2 (2018-05-16)Bug fixes:Do not fail when pyproject.toml file is not there. [maurits] (Issue #2)1.0.0b1 (2018-05-15)New features:First release. [maurits] (Issue #1)