website/blog/git-cliff-2.13.0.md
git-cliff is a command-line tool that provides a highly customizable way to generate changelogs from the Git history.
The full changelog can be found here.
git-cliff now supports defining your own pipeline of commit processing steps via processing_order configuration option!
[git]
processing_order = [
"commit_preprocessors",
"split_commits",
"conventional_commits",
"commit_parsers",
"link_parsers",
]
The available processing steps are:
:::info
This is useful for advanced users who want to have more control over the commit processing pipeline, for example, to run custom preprocessors before the conventional commit parsing step.
:::
We now use the tracing crate for logging in git-cliff!
Before:
After:
Please let us know if you encounter any bugs or UX issues!
git-cliff now supports more configuration file locations!
cliff.toml.cliff.toml.config/cliff.toml$HOME/cliff.toml$HOME/.cliff.toml$HOME/.config/cliff.tomlYou can now get per-commit statistics in the release context:
{% for commit in commits %}
- {{ commit.message }} ({{ commit.statistics.files_changed }} files, +{{ commit.statistics.additions }}, -{{ commit.statistics.deletions }})
{% endfor %}
Results in:
- Fix a bug (3 files, +10, -2)
The available statistics are:
{{ commit.statistics.files_changed }}: Number of files changed in the commit{{ commit.statistics.additions }}: Number of lines added in the commit{{ commit.statistics.deletions }}: Number of lines deleted in the commitThe determined bump type is now available in the release context as {{ bump_type }}.
This can be used to conditionally render content based on the bump type, for example:
{% if bump_type == "major" %}
- This is a major release!
{% endif %}
The available bump types are major, minor and patch.
You can now also set the GIT_CLIFF_OFFLINE environment variable to execute in offline mode:
$ GIT_CLIFF_OFFLINE=true git-cliff
Is the same as:
[remote]
offline = false
Or passing the --offline flag.
There were some updates to the Docker tags pushed from the CI:
latest: only on version tag buildsmain: only on pushes to the main branchsha-<short>: commit SHA builds (e.g. sha-954106f)X.Y.Z: SemVer tag derived from Git tag (e.g. 2.13.0)e.g. to pull the latest stable version, you can now use:
$ docker pull orhun/git-cliff:latest
--with-commit does not change version (#1484) - (3d6a7cb)Any contribution is highly appreciated! See the contribution guidelines for getting started.
Feel free to submit issues and join our Discord / Matrix for discussion!
Follow git-cliff on Twitter & Mastodon to not miss any news!
If you liked git-cliff and/or my other projects on GitHub, consider donating to support my open source endeavors.
Have a fantastic day! ⛰️