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+ body = """
12+ {% if version %}\
13+ ## [{{ version | trim_start_matches(pat="v") }}] - {{ timestamp | date(format="%Y-%m-%d") }}
14+ {% else %}\
15+ ## [unreleased]
16+ {% endif %}\
17+ {% for group, commits in commits | group_by(attribute="group") %}
18+ ### {{ group | upper_first }}
19+ {% for commit in commits %}
20+ - {% if commit.breaking %}[**breaking**] {% endif %}{{ commit.message | upper_first }} ([{{ commit.id | truncate(length=7, end="") }}](https://github.com/wasabeef/git-workers/commit/{{ commit.id }}))
21+ {%- endfor %}
22+ {% endfor %}\n
23+ """
24+ # template for the changelog footer
25+ footer = """
26+ <!-- generated by git-cliff -->
27+ """
28+ # remove the leading and trailing whitespace from the templates
29+ trim = true
30+
31+ [git ]
32+ # parse the commits based on https://www.conventionalcommits.org
33+ conventional_commits = true
34+ # filter out the commits that are not conventional
35+ filter_unconventional = true
36+ # process each line of a commit as an individual commit
37+ split_commits = false
38+ # regex for preprocessing the commit messages
39+ commit_preprocessors = [
40+ { pattern = ' \((\w+\s)?#([0-9]+)\)' , replace = " ([#${2}](https://github.com/wasabeef/git-workers/issues/${2}))" },
41+ ]
42+ # regex for parsing and grouping commits
43+ commit_parsers = [
44+ { message = " ^feat" , group = " Features" },
45+ { message = " ^fix" , group = " Bug Fixes" },
46+ { message = " ^doc" , group = " Documentation" },
47+ { message = " ^perf" , group = " Performance" },
48+ { message = " ^refactor" , group = " Refactor" },
49+ { message = " ^style" , group = " Styling" },
50+ { message = " ^test" , group = " Testing" },
51+ { message = " ^chore\\ (release\\ ): prepare for" , skip = true },
52+ { message = " ^chore\\ (deps\\ )" , skip = true },
53+ { message = " ^chore\\ (pr\\ )" , skip = true },
54+ { message = " ^chore\\ (pull\\ )" , skip = true },
55+ { message = " ^chore|ci" , group = " Miscellaneous Tasks" },
56+ { body = " .*security" , group = " Security" },
57+ { message = " ^revert" , group = " Revert" },
58+ ]
59+ # protect against committing breaking changes
60+ protect_breaking_commits = false
61+ # filter out the commits that are not matched by commit parsers
62+ filter_commits = false
63+ # sort the tags topologically
64+ topo_order = false
65+ # sort the commits inside sections by oldest/newest order
66+ sort_commits = " oldest"
0 commit comments