Skip to content

Commit 0b6c765

Browse files
committed
chore: update changelog format
1 parent e4d3a9b commit 0b6c765

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

β€Žrelease-plz.tomlβ€Ž

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
[changelog]
2+
body = """
3+
4+
## [{{ version }}]\
5+
{%- if release_link -%}\
6+
({{ release_link }})\
7+
{% endif %} \
8+
- {{ timestamp | date(format="%Y-%m-%d") }}
9+
{% for group, commits in commits | group_by(attribute="group") %}
10+
### {{ group | upper_first }}
11+
{% for commit in commits %}
12+
{%- if commit.scope -%}
13+
- *({{commit.scope}})* {% if commit.breaking %}[**breaking**] {% endif %}\
14+
{{ commit.message }}{{ self::username(commit=commit) }}\
15+
{%- if commit.links %} \
16+
({% for link in commit.links %}[{{link.text}}]({{link.href}}) {% endfor -%})\
17+
{% endif %}
18+
{% else -%}
19+
- {% if commit.breaking %}[**breaking**] {% endif %}{{ commit.message }}{{ self::username(commit=commit) }}
20+
{% endif -%}
21+
{% endfor -%}
22+
{% endfor %}
23+
{%- if remote.contributors %}
24+
### Contributors
25+
{% for contributor in remote.contributors %}
26+
* @{{ contributor.username }}
27+
{%- endfor %}
28+
{% endif -%}
29+
{%- macro username(commit) -%}
30+
{% if commit.remote.username %} (by @{{ commit.remote.username }}){% endif -%}
31+
{% endmacro -%}
32+
"""
33+
34+
commit_parsers = [
35+
{ message = "^feat", group = "<!-- 0 -->πŸš€ Features" },
36+
{ message = "^fix", group = "<!-- 1 -->πŸ› Bug Fixes" },
37+
{ message = "^refactor", group = "<!-- 2 -->🚜 Refactor" },
38+
{ message = "^doc", group = "<!-- 3 -->πŸ“š Documentation" },
39+
{ message = "^perf", group = "<!-- 4 -->⚑ Performance" },
40+
{ message = "^style", group = "<!-- 5 -->🎨 Styling" },
41+
{ message = "^test", group = "<!-- 6 -->πŸ§ͺ Testing" },
42+
{ message = "^chore|^ci|^deps", skip = true },
43+
{ body = ".*security", group = "<!-- 7 -->πŸ›‘οΈ Security" },
44+
{ message = "^revert", group = "<!-- 8 -->◀️ Revert" },
45+
{ message = ".*", group = "<!-- 9 -->πŸ’Ό Other" },
46+
]

0 commit comments

Comments
Β (0)