From 1f85263f84bf15285fd3fd75af00fa21b12e9738 Mon Sep 17 00:00:00 2001 From: orhun Date: Tue, 3 Aug 2021 00:33:21 +0300 Subject: [PATCH] fix(template): use 7 digits for short SHA --- examples/detailed.toml | 6 +++--- release.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/examples/detailed.toml b/examples/detailed.toml index 86192dd..0b43b79 100644 --- a/examples/detailed.toml +++ b/examples/detailed.toml @@ -16,14 +16,14 @@ body = """ {% endif %}\ {% if previous %}\ {% if previous.commit_id %} - [{{ previous.commit_id | truncate(length=8, end="") }}]({{ previous.commit_id }})...\ - [{{ commit_id | truncate(length=8, end="") }}]({{ commit_id }}) + [{{ previous.commit_id | truncate(length=7, end="") }}]({{ previous.commit_id }})...\ + [{{ commit_id | truncate(length=7, end="") }}]({{ commit_id }}) {% endif %}\ {% endif %}\ {% for group, commits in commits | group_by(attribute="group") %} ### {{ group | upper_first }} {% for commit in commits %} - - {{ commit.message | upper_first }} ([{{ commit.id | truncate(length=8, end="") }}]({{ commit.id }}))\ + - {{ commit.message | upper_first }} ([{{ commit.id | truncate(length=7, end="") }}]({{ commit.id }}))\ {% endfor %} {% endfor %}\n """ diff --git a/release.sh b/release.sh index a41126a..f134187 100755 --- a/release.sh +++ b/release.sh @@ -13,7 +13,7 @@ if [ -n "$1" ]; then {% for group, commits in commits | group_by(attribute=\"group\") %} {{ group | upper_first }}\ {% for commit in commits %} - - {{ commit.message | upper_first }} ({{ commit.id | truncate(length=8, end=\"\") }})\ + - {{ commit.message | upper_first }} ({{ commit.id | truncate(length=7, end=\"\") }})\ {% endfor %} {% endfor %}" changelog=$(cargo run -- --unreleased --strip all)