Skip to content

Commit d0f9577

Browse files
author
Matéo Fernandez
committed
docs(changelog): add contributors section to changelog
1 parent 455905a commit d0f9577

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

.github/workflows/rust_release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ jobs:
2424
id: git-cliff
2525
with:
2626
config: cliff.toml
27-
args: -vv --latest --strip header
27+
args: --latest --strip header
2828
env:
29-
OUTPUT: CHANGES.md
29+
OUTPUT: CHANGELOG.md
3030
GITHUB_REPO: ${{ github.repository }}
3131

3232
create-release:

cliff.toml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,14 @@ body = """
2626
{{ commit.message | upper_first }}\
2727
{% endfor %}
2828
{% endfor %}\n
29+
{%- if github -%}
30+
{% if github.contributors | filter(attribute="is_first_time", value=true) | length != 0 %}
31+
## New Contributors
32+
{% endif %}\
33+
{% for contributor in github.contributors | filter(attribute="is_first_time", value=true) %}
34+
* @{{ contributor.username }} made their first contribution {%- if contributor.pr_number %}in #{{ contributor.pr_number }}{%- endif %}
35+
{%- endfor -%}
36+
{%- endif %}
2937
"""
3038
# remove the leading and trailing s
3139
trim = true

0 commit comments

Comments
 (0)