Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce towncrier #1201

Merged
merged 25 commits into from
Jan 14, 2024
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
6134831
Introduce towncrier with basic configuration
Gitznik Jan 11, 2024
c7fc62e
Format changelog according to keep a changelog
Gitznik Jan 11, 2024
c4475fb
Add pre-commit hook
Gitznik Jan 11, 2024
e2da3c2
Add changelog entry
Gitznik Jan 11, 2024
d35749f
Update PR template
Gitznik Jan 11, 2024
c08ba9e
Switch to default fragment types
Gitznik Jan 12, 2024
24c3c42
Update .github/PULL_REQUEST_TEMPLATE.md
gaborbernat Jan 12, 2024
7b35d0e
Update news contribution docs
Gitznik Jan 12, 2024
4fbe258
Update bump changelog workflow
Gitznik Jan 12, 2024
7d12bf6
Merge remote-tracking branch 'refs/remotes/origin/introduce_towncrier…
Gitznik Jan 12, 2024
5888008
Merge branch 'main' into introduce_towncrier
Gitznik Jan 12, 2024
c932544
Remove redundant news fragments
Gitznik Jan 12, 2024
8def969
Add empty gitignore file to make sure changelog.d folder is tracked
Gitznik Jan 12, 2024
7b3532e
Apply suggestions from code review
Gitznik Jan 13, 2024
a977247
Add changelog entry
Gitznik Jan 12, 2024
a085950
Build changelog during `build_docs` nox command
Gitznik Jan 13, 2024
30b5113
Moved towncrier changelog entry to docs block
Gitznik Jan 13, 2024
cdcff25
Stop adding version number to top of changelog via mkdocs script
Gitznik Jan 13, 2024
cce41eb
Render current newsfragments cleanly during build docs
Gitznik Jan 13, 2024
efc1df6
Remove extra stdout lines from towncrier build step
Gitznik Jan 13, 2024
cfdd130
Add draft changelog file to gitignore
Gitznik Jan 13, 2024
0e4f166
Add upcoming changes to prod changelog
Gitznik Jan 13, 2024
7512219
Remove draft changelog in site after build
Gitznik Jan 14, 2024
60d0290
Merge branch 'main' into introduce_towncrier
Gitznik Jan 14, 2024
87c7720
Create news fragment for current dev changelog
Gitznik Jan 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- add an 'x' in the brackets below -->

- [ ] I have added an entry to `docs/changelog.md`
- [ ] I have added an entry to `changelog.d`
gaborbernat marked this conversation as resolved.
Show resolved Hide resolved

## Summary of changes

Expand Down
4 changes: 4 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,7 @@ repos:
- "packaging>=20"
- "platformdirs>=2.1"
- "tomli; python_version < '3.11'"
- repo: https://github.com/twisted/towncrier
Gitznik marked this conversation as resolved.
Show resolved Hide resolved
rev: 23.11.0
hooks:
- id: towncrier-check
246 changes: 150 additions & 96 deletions CHANGELOG.md

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions changelog.d/1081.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Allow skipping maintenance tasks during list command
1 change: 1 addition & 0 deletions changelog.d/1089.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Raise more user friendly error when provided `--python` version is not found
1 change: 1 addition & 0 deletions changelog.d/1142.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Include into (zipapp) so that it can be executed with Python 3.10 or earlier
chrysle marked this conversation as resolved.
Show resolved Hide resolved
1 change: 1 addition & 0 deletions changelog.d/1152.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
`pipx run`: Verify whether the script name provided is a file before running it
1 change: 1 addition & 0 deletions changelog.d/1161.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Introduce towncrier for managing the changelog
1 change: 1 addition & 0 deletions changelog.d/1180.changed.1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Update `pipx run` on scripts using `/// script` and no `run` table following the updated version of PEP 723
1 change: 1 addition & 0 deletions changelog.d/1180.changed.md
Gitznik marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Update on scripts using and no table following the updated version of PEP 723
1 change: 1 addition & 0 deletions changelog.d/1192.fixed.md
chrysle marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Avoid repeated exception logging in a few rare cases
2 changes: 1 addition & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

PYTHON_ALL_VERSIONS = ["3.12", "3.11", "3.10", "3.9", "3.8"]
PYTHON_DEFAULT_VERSION = "3.12"
DOC_DEPENDENCIES = ["jinja2", "mkdocs", "mkdocs-material", "mkdocs-gen-files"]
DOC_DEPENDENCIES = ["jinja2", "mkdocs", "mkdocs-material", "mkdocs-gen-files", "towncrier"]
MAN_DEPENDENCIES = ["argparse-manpage[setuptools]"]
TEST_DEPENDENCIES = ["pytest", "pypiserver[passlib]", 'setuptools; python_version>="3.12"', "pytest-cov"]
# Packages whose dependencies need an intact system PATH to compile
Expand Down
9 changes: 9 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,15 @@ lint.mccabe.max-complexity = 15
[tool.pytest.ini_options]
markers = ["all_packages: test install with maximum number of packages"]

[tool.towncrier]
directory = "changelog.d"
filename = "CHANGELOG.md"
start_string = "<!-- towncrier release notes start -->\n"
underlines = ["", "", ""]
title_format = "## [{version}](https://github.com/pypa/pipx/tree/{version}) - {project_date}"
issue_format = "[#{issue}](https://github.com/pypa/pipx/issues/{issue})"
package = "pipx"

[[tool.mypy.overrides]]
module = ["pipx.version", "pycowsay.*"]
ignore_missing_imports = true