commit
1fed71dc64
4 files changed
+143
No files matched your search
+71
@@ -0,0 +1,71 @@
|
||||
# git-cliff configuration — https://git-cliff.org/docs/configuration
|
||||
# Preview locally: npx git-cliff --latest (or: npx git-cliff v0.6.1..v0.7.0)
|
||||
|
||||
[changelog]
|
||||
header = ""
|
||||
# Group names carry an HTML comment prefix so sections sort in a fixed order; `striptags` removes it when rendering.
|
||||
body = """
|
||||
{%- set server = get_env(name="GITHUB_SERVER_URL", default="") -%}
|
||||
{%- set repository = get_env(name="GITHUB_REPOSITORY", default="") -%}
|
||||
{% if version %}\
|
||||
# Release Notes for {{ version }}
|
||||
{% else %}\
|
||||
# Unreleased
|
||||
{% endif %}
|
||||
{%- set breaking_commits = commits | filter(attribute="breaking", value=true) %}
|
||||
{% if breaking_commits | length > 0 %}
|
||||
## :warning: Breaking changes
|
||||
{% for commit in breaking_commits %}
|
||||
- {% if commit.scope %}**{{ commit.scope }}**: {% endif %}{{ commit.breaking_description | default(value=commit.message) | upper_first }} ({{ commit.id | truncate(length=7, end="") }})
|
||||
{%- endfor %}
|
||||
{% endif %}
|
||||
{%- for group, group_commits in commits | group_by(attribute="group") %}
|
||||
## {{ group | striptags | trim }}
|
||||
{% for commit in group_commits %}
|
||||
- {% if commit.scope %}**{{ commit.scope }}**: {% endif %}{{ commit.message | upper_first }} ({{ commit.id | truncate(length=7, end="") }})
|
||||
{%- endfor %}
|
||||
{% endfor %}
|
||||
{%- set authors = commits | map(attribute="author.name") | unique | sort %}
|
||||
{% if authors | length > 0 %}
|
||||
## Contributors
|
||||
{% for author in authors %}
|
||||
* {{ author }}
|
||||
{%- endfor %}
|
||||
{% endif %}
|
||||
{% if server and repository and version %}
|
||||
{%- if previous.version %}
|
||||
**Full Changelog**: [{{ previous.version }}...{{ version }}]({{ server }}/{{ repository }}/compare/{{ previous.version }}...{{ version }})
|
||||
{%- else %}
|
||||
**Full Changelog**: [{{ version }}]({{ server }}/{{ repository }}/commits/tag/{{ version }})
|
||||
{%- endif %}
|
||||
{% endif %}
|
||||
"""
|
||||
footer = ""
|
||||
trim = true
|
||||
postprocessors = [
|
||||
{ pattern = '\n{3,}', replace = "\n\n" },
|
||||
]
|
||||
|
||||
[git]
|
||||
conventional_commits = true
|
||||
# Drops merge/squash commits such as "Develop (!259)" or "Merge Develop into Main (!250)".
|
||||
filter_unconventional = true
|
||||
split_commits = false
|
||||
protect_breaking_commits = true
|
||||
filter_commits = false
|
||||
tag_pattern = "v[0-9].*"
|
||||
sort_commits = "newest"
|
||||
commit_parsers = [
|
||||
{ message = "^(?i)merge", skip = true },
|
||||
{ message = "^(?i)feat", group = "<!-- 0 -->:rocket: Features" },
|
||||
{ message = "^(?i)(fix|hotfix)", group = "<!-- 1 -->:bug: Bug Fixes" },
|
||||
{ message = "^(?i)(improve|enhancement|perf)", group = "<!-- 2 -->:zap: Improvements" },
|
||||
{ message = "^(?i)refactor", group = "<!-- 3 -->:recycle: Refactor" },
|
||||
{ message = "^(?i)migration", group = "<!-- 4 -->:card_file_box: Database Migrations" },
|
||||
{ message = "^(?i)docs?", group = "<!-- 5 -->:memo: Documentation" },
|
||||
{ message = "^(?i)style", group = "<!-- 6 -->:art: Styling" },
|
||||
{ message = "^(?i)test", group = "<!-- 7 -->:white_check_mark: Tests" },
|
||||
{ message = "^(?i)(ci|build)", group = "<!-- 8 -->:construction_worker: CI/CD" },
|
||||
{ message = "^(?i)chore", group = "<!-- 9 -->:wrench: Chores" },
|
||||
{ message = ".*", group = "<!-- 10 -->:card_index: Other" },
|
||||
]
|
||||
Reference in new issue
Block a user