Repository navigation
Expand file tree
/
Copy pathcliff.toml
More file actions
69 lines (63 loc) · 2.42 KB
/
Copy pathcliff.toml
File metadata and controls
69 lines (63 loc) · 2.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# cliff.toml — generic Conventional Commits changelog for any GitHub repo.
#
# owner/repo are auto-detected from `git remote get-url origin`.
# Override here only when auto-detection fails (e.g. non-standard remotes):
#
# [remote.github]
# owner = "my-org"
# repo = "my-repo"
#
# Requires: git-cliff >= 2.0 (https://github.com/orhun/git-cliff)
[remote.github]
[changelog]
header = "# Changelog\n"
body = """
{% if version %}\
{% set base = "https://github.com/" ~ remote.github.owner ~ "/" ~ remote.github.repo -%}
## [{{ version }}]\
({% if previous.version %}{{ base }}/compare/{{ previous.version }}...{{ version }}\
{% else %}{{ base }}/releases/tag/{{ version }}{% endif %}) \
- {{ timestamp | date(format="%Y-%m-%d") }}
{% else %}\
## [Unreleased]
{% endif %}\
{% for group, commits in commits | group_by(attribute="group") %}\
### {{ group | upper_first }}
{% for commit in commits %}\
- {{ commit.message | upper_first }}\
{% if commit.breaking %} ⚠ **BREAKING CHANGE**{% endif %} \
([`{{ commit.id | truncate(length=7, end="") }}`]\
({{ base }}/commit/{{ commit.id }}))
{% endfor %}
{% endfor %}\
"""
trim = true
footer = ""
[git]
conventional_commits = true
filter_unconventional = false
split_commits = false
commit_preprocessors = [
# Optional: turn #123 into a GitHub issue link.
# replace uses regex substitution, not Tera — set owner/repo explicitly:
# { pattern = '#([0-9]+)', replace = "[#$1](https://github.com/ORG/REPO/issues/$1)" },
]
commit_parsers = [
{ message = "^feat", group = "New features" },
{ message = "^fix", group = "Bug fixes" },
{ message = "^perf", group = "Performance" },
{ message = "^revert", group = "Reverted" },
{ message = "^refactor", group = "Refactoring" },
{ message = "^docs", group = "Documentation" },
{ message = "^test", group = "Testing" },
{ message = "^build", group = "Build system" },
{ message = "^ci", group = "CI/CD" },
{ message = "^style", skip = true },
{ message = "^chore\\(release\\)", skip = true },
{ message = "^chore", group = "Miscellaneous" },
{ message = ".*", group = "Miscellaneous" },
]
protect_breaking_commits = true
filter_commits = false
tag_pattern = "v[0-9]+\\.[0-9]+\\.[0-9]+"
sort_commits = "oldest"