From bebe95bc706d6a5999c67dddd44572e3c0e5bba4 Mon Sep 17 00:00:00 2001 From: Carmen Bianca BAKKER Date: Mon, 1 Jul 2024 15:00:59 +0200 Subject: [PATCH 1/6] Add dev dependency on protokolo Signed-off-by: Carmen Bianca BAKKER --- poetry.lock | 18 +++++++++++++++++- pyproject.toml | 1 + 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/poetry.lock b/poetry.lock index bf566915..78a09592 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1074,6 +1074,22 @@ nodeenv = ">=0.11.1" pyyaml = ">=5.1" virtualenv = ">=20.10.0" +[[package]] +name = "protokolo" +version = "2.1.4" +description = "Protokolo is a change log generator." +category = "dev" +optional = false +python-versions = "<4.0,>=3.11" +files = [ + {file = "protokolo-2.1.4-cp311-cp311-manylinux_2_36_x86_64.whl", hash = "sha256:b10ff72199e5ced3fd662a5b870b673bf37a5c990dd4eacf054bdf3ea5f2e359"}, + {file = "protokolo-2.1.4.tar.gz", hash = "sha256:451addc697e43a2aac4db612acf747ffe839686e5ea71018a5bc1ea5adeddc08"}, +] + +[package.dependencies] +attrs = ">=22.1.0" +click = ">=8.0" + [[package]] name = "pygments" version = "2.18.0" @@ -1804,4 +1820,4 @@ testing = ["big-O", "jaraco.functools", "jaraco.itertools", "more-itertools", "p [metadata] lock-version = "2.0" python-versions = "^3.8" -content-hash = "14a038a5fa48006c3394fee5efc29aef8a6b335d8c78c97d94e5e9e0b77bd44a" +content-hash = "057ae26f33e216758289466ff694ada751ccb92f81e593872d81a5f6f0312724" diff --git a/pyproject.toml b/pyproject.toml index 78afee2f..168b96a6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -80,6 +80,7 @@ bumpver = ">=2023.1129" pylint = ">=2.12.2" mypy = ">=1.0" GitPython = ">=3.0" +protokolo = { version = ">=2.1.0", python = "^3.11" } [tool.poetry.group.lsp] optional = true From e24c7b883e7cadfe09ac8954946d3a61acbb988a Mon Sep 17 00:00:00 2001 From: Carmen Bianca BAKKER Date: Mon, 1 Jul 2024 15:01:14 +0200 Subject: [PATCH 2/6] Set up Protokolo scaffolding Signed-off-by: Carmen Bianca BAKKER --- changelog.d/.protokolo.toml | 3 +++ changelog.d/added/.protokolo.toml | 3 +++ changelog.d/changed/.protokolo.toml | 3 +++ changelog.d/deprecated/.protokolo.toml | 3 +++ changelog.d/fixed/.protokolo.toml | 3 +++ changelog.d/removed/.protokolo.toml | 3 +++ changelog.d/security/.protokolo.toml | 3 +++ pyproject.toml | 5 +++++ 8 files changed, 26 insertions(+) create mode 100644 changelog.d/.protokolo.toml create mode 100644 changelog.d/added/.protokolo.toml create mode 100644 changelog.d/changed/.protokolo.toml create mode 100644 changelog.d/deprecated/.protokolo.toml create mode 100644 changelog.d/fixed/.protokolo.toml create mode 100644 changelog.d/removed/.protokolo.toml create mode 100644 changelog.d/security/.protokolo.toml diff --git a/changelog.d/.protokolo.toml b/changelog.d/.protokolo.toml new file mode 100644 index 00000000..2c1d908b --- /dev/null +++ b/changelog.d/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "${version} - ${date}" +level = 2 diff --git a/changelog.d/added/.protokolo.toml b/changelog.d/added/.protokolo.toml new file mode 100644 index 00000000..59a8276b --- /dev/null +++ b/changelog.d/added/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "Added" +order = 1 diff --git a/changelog.d/changed/.protokolo.toml b/changelog.d/changed/.protokolo.toml new file mode 100644 index 00000000..f20b10c6 --- /dev/null +++ b/changelog.d/changed/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "Changed" +order = 2 diff --git a/changelog.d/deprecated/.protokolo.toml b/changelog.d/deprecated/.protokolo.toml new file mode 100644 index 00000000..adb5f421 --- /dev/null +++ b/changelog.d/deprecated/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "Deprecated" +order = 3 diff --git a/changelog.d/fixed/.protokolo.toml b/changelog.d/fixed/.protokolo.toml new file mode 100644 index 00000000..a6144895 --- /dev/null +++ b/changelog.d/fixed/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "Fixed" +order = 5 diff --git a/changelog.d/removed/.protokolo.toml b/changelog.d/removed/.protokolo.toml new file mode 100644 index 00000000..a1da3dca --- /dev/null +++ b/changelog.d/removed/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "Removed" +order = 4 diff --git a/changelog.d/security/.protokolo.toml b/changelog.d/security/.protokolo.toml new file mode 100644 index 00000000..1e4e5768 --- /dev/null +++ b/changelog.d/security/.protokolo.toml @@ -0,0 +1,3 @@ +[protokolo.section] +title = "Security" +order = 6 diff --git a/pyproject.toml b/pyproject.toml index 168b96a6..5a8c4924 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -123,6 +123,11 @@ push = false '__version__ = "{pep440_version}"$', ] +[tool.protokolo] +changelog = "CHANGELOG.md" +markup = "markdown" +directory = "changelog.d" + [tool.black] line-length = 80 From 1efb36eb9cf320964837b2ca96f5d7569d5c0580 Mon Sep 17 00:00:00 2001 From: Carmen Bianca BAKKER Date: Mon, 1 Jul 2024 15:07:12 +0200 Subject: [PATCH 3/6] Improve change log documentation in CONTRIBUTING Signed-off-by: Carmen Bianca BAKKER --- CONTRIBUTING.md | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index be86b31b..6da99c5e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -48,9 +48,25 @@ feature that may not be accepted. When making a pull request, don't hesitate to add yourself to the AUTHORS.rst file and the copyright headers of the files you touch. -Every pull request should add an entry in `CHANGELOG.md`. Some exceptions apply, -such as changes which are too tiny to be significant, certain refactorings, or -fixes to pull requests which were already merged, but not yet released. +### Change log + +Every pull request should add a change log entry. Change log entries go into +`changelog.d//.md`, where `` is the appropriate +category for the change set, and where `` is a short or random name for +your change set. + +The contents of the file should typically look like this: + +```markdown +- Added a new feature. (#pr_number) +``` + +At release time, the contents of the `changelog.d/` directory are compiled into +`CHANGELOG.md` using `protokolo compile`. + +Some PRs are excepted from adding change log entries, such as changes which are +too tiny to be significant, certain refactorings, or fixes to pull requests +which were already merged, but not yet released. ## Translation From 5d9e9bab842fcffbf8e2aff62d731b2b68e8e517 Mon Sep 17 00:00:00 2001 From: Carmen Bianca BAKKER Date: Mon, 1 Jul 2024 15:08:20 +0200 Subject: [PATCH 4/6] Add Protokolo section tag to change log Signed-off-by: Carmen Bianca BAKKER --- CHANGELOG.md | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 44ae7276..bcbcd2ff 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,21 +23,7 @@ The versions follow [semantic versioning](https://semver.org) for the `reuse` CLI command and its behaviour. There are no guarantees of stability for the `reuse` Python library. - + ## Unreleased - YYYY-MM-DD From 2c24357af0218a724f4a46411189f266460a54e4 Mon Sep 17 00:00:00 2001 From: Carmen Bianca BAKKER Date: Mon, 1 Jul 2024 15:18:47 +0200 Subject: [PATCH 5/6] Added a pull request template Signed-off-by: Carmen Bianca BAKKER --- .github/pull_request_template.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/pull_request_template.md diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 00000000..5abc73af --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,16 @@ + + + + +- [ ] Added a change log entry in `changelog.d//`. +- [ ] Added self to copyright blurb of touched files. +- [ ] Added self to `AUTHORS.rst`. +- [ ] Wrote tests. +- [ ] (Situational) Documented my changes in `docs/man/`. +- [x] I agree to license my contribution under the licenses indicated in the + changed files. From 402db02b3d80ef7caefd16e773527bd7b7ff53fd Mon Sep 17 00:00:00 2001 From: Carmen Bianca BAKKER Date: Mon, 1 Jul 2024 15:33:42 +0200 Subject: [PATCH 6/6] Make Protokolo REUSE-compliant Signed-off-by: Carmen Bianca BAKKER --- REUSE.toml | 9 +++++++-- changelog.d/.protokolo.toml | 4 ++++ changelog.d/added/.protokolo.toml | 4 ++++ changelog.d/changed/.protokolo.toml | 4 ++++ changelog.d/deprecated/.protokolo.toml | 4 ++++ changelog.d/fixed/.protokolo.toml | 4 ++++ changelog.d/removed/.protokolo.toml | 4 ++++ changelog.d/security/.protokolo.toml | 4 ++++ 8 files changed, 35 insertions(+), 2 deletions(-) diff --git a/REUSE.toml b/REUSE.toml index 989ff511..71c5e87c 100644 --- a/REUSE.toml +++ b/REUSE.toml @@ -50,7 +50,12 @@ SPDX-FileCopyrightText = "2017 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "${version} - ${date}" level = 2 diff --git a/changelog.d/added/.protokolo.toml b/changelog.d/added/.protokolo.toml index 59a8276b..bd892422 100644 --- a/changelog.d/added/.protokolo.toml +++ b/changelog.d/added/.protokolo.toml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2024 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "Added" order = 1 diff --git a/changelog.d/changed/.protokolo.toml b/changelog.d/changed/.protokolo.toml index f20b10c6..9d91d23a 100644 --- a/changelog.d/changed/.protokolo.toml +++ b/changelog.d/changed/.protokolo.toml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2024 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "Changed" order = 2 diff --git a/changelog.d/deprecated/.protokolo.toml b/changelog.d/deprecated/.protokolo.toml index adb5f421..5264d668 100644 --- a/changelog.d/deprecated/.protokolo.toml +++ b/changelog.d/deprecated/.protokolo.toml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2024 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "Deprecated" order = 3 diff --git a/changelog.d/fixed/.protokolo.toml b/changelog.d/fixed/.protokolo.toml index a6144895..48f9fed3 100644 --- a/changelog.d/fixed/.protokolo.toml +++ b/changelog.d/fixed/.protokolo.toml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2024 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "Fixed" order = 5 diff --git a/changelog.d/removed/.protokolo.toml b/changelog.d/removed/.protokolo.toml index a1da3dca..21a87a44 100644 --- a/changelog.d/removed/.protokolo.toml +++ b/changelog.d/removed/.protokolo.toml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2024 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "Removed" order = 4 diff --git a/changelog.d/security/.protokolo.toml b/changelog.d/security/.protokolo.toml index 1e4e5768..df2c43a6 100644 --- a/changelog.d/security/.protokolo.toml +++ b/changelog.d/security/.protokolo.toml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2024 Free Software Foundation Europe e.V. +# +# SPDX-License-Identifier: CC0-1.0 + [protokolo.section] title = "Security" order = 6