chore: list Renovate's security updates in the changelog #97

Merged
keb merged 1 commits from chore/security-changelog into main 2026-11-12 10:26:12 +01:00
3 changed files with 9 additions and 4 deletions

No files matched your search

+5 -3
View File
@@ -1,8 +1,9 @@
# git-cliff (https://git-cliff.org) builds CHANGELOG.md and the release # git-cliff (https://git-cliff.org) builds CHANGELOG.md and the release
# notes from the commits on main. Pull requests are squash-merged, so each # notes from the commits on main. Pull requests are squash-merged, so each
# one is a single commit whose message is the PR title: a conventional one # one is a single commit whose message is the PR title: a conventional one
# (feat: …, fix: …, perf: …) puts it in the changelog, anything else # (feat: …, fix: …, perf: …) puts it in the changelog, and so does a
# (chore, ci, docs, refactor, test, …) leaves it out. # dependency update Renovate marks [security]; anything else (chore, ci,
# docs, refactor, test, …) leaves it out.
# #
# git cliff --unreleased # what the next release would say # git cliff --unreleased # what the next release would say
@@ -24,7 +25,7 @@ Hello world 👋
{% for group, commits in commits | group_by(attribute="group") %} {% for group, commits in commits | group_by(attribute="group") %}
### {{ group | striptags | trim }} ### {{ group | striptags | trim }}
{% for commit in commits %} {% for commit in commits %}
- {% if commit.breaking %}**Breaking:** {% endif %}{{ commit.message | split(pat="\n") | first | upper_first | trim }} \ - {% if commit.breaking %}**Breaking:** {% endif %}{{ commit.message | split(pat="\n") | first | replace(from=" [security]", to="") | upper_first | trim }} \
([{{ commit.id | truncate(length=7, end="") }}](https://git.kebcloud.no/keb/lazysecrets/commit/{{ commit.id }}))\ ([{{ commit.id | truncate(length=7, end="") }}](https://git.kebcloud.no/keb/lazysecrets/commit/{{ commit.id }}))\
{% endfor %} {% endfor %}
{% endfor %}\n {% endfor %}\n
@@ -65,5 +66,6 @@ commit_parsers = [
{ message = "^feat", group = "<!-- 0 -->Added" }, { message = "^feat", group = "<!-- 0 -->Added" },
{ message = "^perf", group = "<!-- 1 -->Changed" }, { message = "^perf", group = "<!-- 1 -->Changed" },
{ message = "^fix", group = "<!-- 2 -->Fixed" }, { message = "^fix", group = "<!-- 2 -->Fixed" },
{ message = "\\[security\\]", group = "<!-- 3 -->Security" },
{ message = ".*", skip = true }, { message = ".*", skip = true },
] ]
+3
View File
@@ -35,6 +35,9 @@ subject, checked by `pr-title.yml`:
| `fix` | a bug fix | Fixed | | `fix` | a bug fix | Fixed |
| `refactor`, `docs`, `test`, `ci`, `chore`, `build`, `style`, `revert` | everything users don't need to hear about | no | | `refactor`, `docs`, `test`, `ci`, `chore`, `build`, `style`, `revert` | everything users don't need to hear about | no |
Renovate's dependency updates for a vulnerability (`[security]` in the
title) are listed under Security.
`feat!:` marks a breaking change, `feat(scope):` names a part. `feat!:` marks a breaking change, `feat(scope):` names a part.
`[skip changelog]` in the description leaves a pull request out. `[skip changelog]` in the description leaves a pull request out.
+1 -1
View File
@@ -55,7 +55,7 @@ echo "$tag$bumped"
notes=$(git cliff --unreleased --tag "$tag" --strip all) notes=$(git cliff --unreleased --tag "$tag" --strip all)
if ! grep -q '^- ' <<<"$notes"; then if ! grep -q '^- ' <<<"$notes"; then
echo "Nothing for the changelog since the last release (no feat/fix/perf pull requests)." >&2 echo "Nothing for the changelog since the last release (no feat/fix/perf or [security] pull requests)." >&2
$dry || exit 1 $dry || exit 1
fi fi
echo "$notes" echo "$notes"