cliff.toml 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. # git-cliff configuration file
  2. # https://git-cliff.org/docs/configuration
  3. #
  4. # Lines starting with "#" are comments.
  5. # Configuration options are organized into tables and keys.
  6. # See documentation for more information on available options.
  7. [changelog]
  8. header = """
  9. ## What's new
  10. """
  11. # template for the changelog body
  12. # https://tera.netlify.app/docs
  13. body = """
  14. {% for group, commits in commits | group_by(attribute="group") %}\
  15. {% for commit in commits %}
  16. - {{ commit.message | upper_first | split(pat="\n") | first | trim }}\
  17. {% if commit.remote.username %} by @{{ commit.remote.username }}{%- endif %}\
  18. {% endfor %}\
  19. {% endfor %}
  20. """
  21. # remove the leading and trailing whitespace from the template
  22. trim = true
  23. footer = """
  24. """
  25. postprocessors = [ ]
  26. [git]
  27. # parse the commits based on https://www.conventionalcommits.org
  28. conventional_commits = true
  29. # filter out the commits that are not conventional
  30. filter_unconventional = false
  31. # process each line of a commit as an individual commit
  32. split_commits = false
  33. # regex for preprocessing the commit messages
  34. commit_preprocessors = []
  35. # regex for parsing and grouping commits
  36. commit_parsers = [
  37. { message = "^build\\(deps\\)", skip = true },
  38. { message = "^build\\(deps-dev\\)", skip = true },
  39. { message = "^ci", skip = true },
  40. { body = ".*", group = "Changes" },
  41. ]
  42. # protect breaking changes from being skipped due to matching a skipping commit_parser
  43. protect_breaking_commits = false
  44. # filter out the commits that are not matched by commit parsers
  45. filter_commits = false
  46. # glob pattern for matching git tags
  47. tag_pattern = "v[0-9]*"
  48. # regex for skipping tags
  49. skip_tags = ""
  50. # regex for ignoring tags
  51. ignore_tags = ""
  52. # sort the tags topologically
  53. topo_order = false
  54. # sort the commits inside sections by oldest/newest order
  55. sort_commits = "newest"
  56. # limit the number of commits included in the changelog.
  57. # limit_commits = 42