-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcliff.toml
More file actions
60 lines (57 loc) · 2.56 KB
/
Copy pathcliff.toml
File metadata and controls
60 lines (57 loc) · 2.56 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
# git-cliff ~ configuration file
# https://git-cliff.org/docs/configuration
[changelog]
header = """
# Changelog
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
"""
postprocessors = [
{ pattern = '<!-- \d+ -->', replace = "" },
]
body = """\
{% set repo_url = "https://github.com/allohamora/cli" %}\
{% if get_env(name="REMOVE_TITLE", default="") == "" %}\
{% if version %}\
{% if previous.version %}\
\n## [{{ version | trim_start_matches(pat="v") }}]({{ repo_url }}/compare/{{ previous.version }}...{{ version }}) ({{ timestamp | date(format="%Y-%m-%d") }})\n\n\
{% else %}\
\n## {{ version | trim_start_matches(pat="v") }} ({{ timestamp | date(format="%Y-%m-%d") }})\n\n\
{% endif %}\
{% else %}\
\n## [Unreleased]\n\n\
{% endif %}\
{% endif %}\
{% for group, commits in commits | group_by(attribute="group") %}\
{% if not loop.first %}\
\n\
{% endif %}\
### {{ group | upper_first }}\n\
\n\
{% for commit in commits %}\
- {% if commit.scope %}**{{ commit.scope }}:** {% endif %}{{ commit.message | split(pat="\n") | first | upper_first }}{% if commit.breaking_description and commit.breaking_description != commit.message %} → {{ commit.breaking_description }}{% endif %} ([{{ commit.id | truncate(length=7, end="") }}]({{ repo_url }}/commit/{{ commit.id }}))\n\
{% endfor %}\
{% endfor %}
"""
[git]
filter_unconventional = false
commit_parsers = [
{ message = "^\\w+(\\([^)]*\\))?!:", group = "<!-- 00 -->⚠ BREAKING CHANGES" },
{ footer = "^BREAKING CHANGE:", group = "<!-- 00 -->⚠ BREAKING CHANGES" },
{ message = "^feat", group = "<!-- 01 -->Features" },
{ message = "^fix", group = "<!-- 02 -->Bug Fixes" },
{ message = "^perf", group = "<!-- 03 -->Performance Improvements" },
{ message = "^revert", group = "<!-- 04 -->Reverts" },
{ message = "^refactor", group = "<!-- 05 -->Code Refactoring" },
{ message = "^style", group = "<!-- 06 -->Styles" },
{ message = "^test", group = "<!-- 07 -->Tests" },
{ message = "^docs", group = "<!-- 08 -->Documentation" },
{ message = "^chore: release v\\d+\\.\\d+\\.\\d+", skip = true },
{ message = "^Merge pull request", skip = true },
{ message = "^Merge branch", skip = true },
{ message = "^Merge remote-tracking branch", skip = true },
{ message = "^build", group = "<!-- 09 -->Build System" },
{ message = "^ci", group = "<!-- 10 -->Continuous Integration" },
{ message = "^chore", group = "<!-- 11 -->Miscellaneous Chores" },
{ message = ".*", group = "<!-- 12 -->Other" },
]