81 lines
2.5 KiB
TOML
81 lines
2.5 KiB
TOML
[remote.github]
|
|
owner = "1204244136" # 替换为你的GitHub用户名
|
|
repo = "DoroHelper" # 替换为你的仓库名
|
|
|
|
[changelog]
|
|
header = """
|
|
# 更新日志
|
|
"""
|
|
|
|
body = """
|
|
{%- macro remote_url() -%}
|
|
https://github.com/{{ remote.github.owner }}/{{ remote.github.repo }}
|
|
{%- endmacro -%}
|
|
|
|
{% macro print_commit(commit) -%}
|
|
- {% if commit.scope %}*({{ commit.scope }})* {% endif %}\
|
|
{% if commit.breaking %}[**breaking**] {% endif %}\
|
|
{{ commit.message | upper_first }} \
|
|
({{ commit.id }}) \
|
|
@{{ author.login | default(value=commit.author.name) }}
|
|
{% endmacro -%}
|
|
|
|
{% if version %}\
|
|
## {{ version | trim_start_matches(pat="v") }} ({{ timestamp | date(format="%Y-%m-%d") }})
|
|
{% else %}\
|
|
## 未发布
|
|
{% endif %}\
|
|
|
|
{% for group, commits in commits | group_by(attribute="group") %}
|
|
### {{ group | striptags | trim | upper_first }}
|
|
{% for commit in commits
|
|
| filter(attribute="scope")
|
|
| sort(attribute="scope") %}
|
|
{{ self::print_commit(commit=commit) }}
|
|
{%- endfor %}
|
|
{% for commit in commits %}
|
|
{%- if not commit.scope -%}
|
|
{{ self::print_commit(commit=commit) }}
|
|
{% endif -%}
|
|
{% endfor -%}
|
|
{% endfor -%}
|
|
{%- if github -%}
|
|
{% if github.contributors | filter(attribute="is_first_time", value=true) | length != 0 %}
|
|
## 新贡献者 ❤️
|
|
{% endif %}\
|
|
{% for contributor in github.contributors | filter(attribute="is_first_time", value=true) %}
|
|
* @{{ contributor.username }} made their first contribution
|
|
{%- if contributor.pr_number %} in \
|
|
[#{{ contributor.pr_number }}]({{ self::remote_url() }}/pull/{{ contributor.pr_number }}) \
|
|
{%- endif %}
|
|
{%- endfor -%}
|
|
{%- endif %}
|
|
"""
|
|
|
|
footer = """
|
|
|
|
"""
|
|
|
|
[git]
|
|
conventional_commits = true
|
|
filter_unconventional = false
|
|
commit_parsers = [
|
|
{ message = "^feat", group = "✨ 新功能" },
|
|
{ message = "^fix", group = "🐛 Bug修复" },
|
|
{ message = "^perf", group = "🚀 性能优化" },
|
|
{ message = "^docs", group = "📚 文档" },
|
|
{ message = "^refactor", group = "🚜 代码重构" },
|
|
{ message = "^style", group = "🎨 样式" },
|
|
{ message = "^test", group = "🧪 测试" },
|
|
{ message = "^build", group = "📦 依赖更新" },
|
|
{ message = "^chore", group = "🔧 日常维护" },
|
|
{ message = "^ci", group = "⚙️ 持续集成" },
|
|
{ body = ".*security", group = "🔒 安全" },
|
|
{ message = "^revert", group = "◀️ 撤销" },
|
|
]
|
|
|
|
ignore_tags = "rc"
|
|
sort_commits = "oldest"
|
|
|
|
[git.github]
|
|
commits = true |