Skip to main content

What's new in 2.6.0? πŸ†•

Β· 3 min read
Orhun ParmaksΔ±z
Author of git-cliff

git-cliff is a command-line tool (written in Rust) that provides a highly customizable way to generate changelogs from git history.

It supports using custom regular expressions to alter changelogs which are mostly based on conventional commits. With a single configuration file, a wide variety of formats can be applied for a changelog, thanks to the Jinja2/Django-inspired template engine.

More information and examples can be found in the GitHub repository.

What's new? ⛰️​

The full changelog can be found here.


πŸ› οΈ Deprecated integration fields​

The following fields are deprecated and will be removed in the next releases:

  • commit.github, commit.gitea, commit.gitlab, commit.bitbucket

You can now use the commit.remote field instead. For example:

-{% if commit.github.username %}
+{% if commit.remote.username %}

🌲 Better branch support​

If you have diverged branches for your project and want to changelog for each branch, you can now use the --use-branch-tags option.

$ git cliff --use-branch-tags

The generated changelog above will only include the tags from the current branch.

Also, you can use it from the configuration file:

[git]
use_branch_tags = true
info

See the implementation for more explanation and the coolest hand-drawn diagram ever!


♾️ Render always​

Do you want to always render the changelog even if there are no changes? Boom, now you can now use the render_always option:

[changelog]
render_always = true

πŸ“€ Output from configuration​

This is pretty self-explanatory:

[changelog]
output = "CHANGELOG.md"

This option does not take precedence over command-line arguments which means you can override it with the --output option.


πŸ“¦ Improve Typescript API​

We added the missing options and documented all options with tsdoc comments.

Also, we improved the skipCommit option to accept an array of values.

info

See the implementation for more information.


βœ‚οΈ Trim commit messages​

We now remove the trailing newline for commits, which means you can use $ anchor in your regular expressions:

[git]
commit_preprocessors = [
# remove the issue number at the end of the commit message (e.g. #123)
{ pattern = ' #\d+$', replace = ""}
]

🌟 Better example templates​

The example templates are now more intuitive and conventionally correct. We removed the non-beginner-friendly options and changed the defaults to be easier to start with. Weheee!


🧰 Other​

  • (template) [breaking/core] Add name parameter to the constructor - (e577113)
  • (bump) Suppress template warning when --bumped-version is used (#855) - (8bebbf9)
  • (changelog) Do not change the tag date if tag already exists (#861) - (fbb643b)
  • (changelog) Correctly set the tag message for the latest release (#854) - (e41e8dd)
  • (changelog) Don't change the context when provided via --from-context (#820) - (ff72406)

Contributions πŸ‘₯​

  • @nejcgalof made their first contribution in #853
  • @pplmx made their first contribution in #824

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!

Support πŸŒŸβ€‹

If you liked git-cliff and/or my other projects on GitHub, consider donating to support my open source endeavors.

Have a fantastic day! ⛰️