1+ # git-cliff ~ configuration file
2+ # https://git-cliff.org/docs/configuration
3+
4+ [changelog ]
5+ # changelog header
6+ header = """
7+ # Changelog\n
8+ All notable changes to this project will be documented in this file.\n
9+ """
10+ # template for the changelog body
11+ # https://keats.github.io/tera/docs/#introduction
12+ body = """
13+ {% if version %}\
14+ ## [{{ version | trim_start_matches(pat="v") }}] - {{ timestamp | date(format="%Y-%m-%d") }}
15+ {% else %}\
16+ ## [unreleased]
17+ {% endif %}\
18+ {% if previous %}\
19+ {% if previous.commit_id %}
20+ [{{ previous.commit_id | truncate(length=7, end="") }}]({{ previous.commit_id }})...\
21+ [{{ commit_id | truncate(length=7, end="") }}]({{ commit_id }})
22+ {% endif %}\
23+ {% endif %}\
24+ {% for group, commits in commits | group_by(attribute="group") %}
25+ ### {{ group | upper_first }}
26+ {% for commit in commits %}
27+ - {{ commit.message | upper_first }} ([{{ commit.id | truncate(length=7, end="") }}]({{ commit.id }}))\
28+ {% for footer in commit.footers -%}
29+ , {{ footer.token }}{{ footer.separator }}{{ footer.value }}\
30+ {% endfor %}\
31+ {% endfor %}
32+ {% endfor %}\n
33+ """
34+ # template for the changelog footer
35+ footer = """
36+ <!-- generated by git-cliff -->
37+ """
38+ # remove the leading and trailing whitespace from the templates
39+ trim = true
40+
41+ [git ]
42+ # parse the commits based on https://www.conventionalcommits.org
43+ conventional_commits = true
44+ # filter out the commits that are not conventional
45+ filter_unconventional = true
46+ # process each line of a commit as an individual commit
47+ split_commits = false
48+ # regex for parsing and grouping commits
49+ commit_parsers = [
50+ { message = " ^feat" , group = " Features" },
51+ { message = " ^fix" , group = " Bug Fixes" },
52+ { message = " ^doc" , group = " Documentation" },
53+ { message = " ^perf" , group = " Performance" },
54+ { message = " ^refactor" , group = " Refactor" },
55+ { message = " ^style" , group = " Styling" },
56+ { message = " ^test" , group = " Testing" },
57+ { message = " ^chore\\ (deps.*\\ )" , skip = true },
58+ { message = " ^chore\\ (pr\\ )" , skip = true },
59+ { message = " ^chore\\ (pull\\ )" , skip = true },
60+ { message = " ^chore\\ (release\\ ): prepare for" , skip = true },
61+ { message = " ^chore|^ci" , group = " Miscellaneous Tasks" },
62+ { body = " .*security" , group = " Security" },
63+ ]
64+ # protect breaking changes from being skipped due to matching a skipping commit_parser
65+ protect_breaking_commits = false
66+ # filter out the commits that are not matched by commit parsers
67+ filter_commits = false
68+ # regex for matching git tags
69+ tag_pattern = " v[0-9].*"
70+ # regex for skipping tags
71+ skip_tags = " v0.1.0-beta.1"
72+ # regex for ignoring tags
73+ ignore_tags = " "
74+ # sort the tags topologically
75+ topo_order = false
76+ # sort the commits inside sections by oldest/newest order
77+ sort_commits = " oldest"
0 commit comments