From 0e7d7b87f33b5ec8c75a3a0a9b16fae082d06348 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Cornell=C3=A0?= Date: Wed, 7 Jul 2021 10:40:05 +0200 Subject: [PATCH] feat(changelog): ignore merge commits --- tools/changelog.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/changelog.sh b/tools/changelog.sh index 836afef14..56ea42cb1 100755 --- a/tools/changelog.sh +++ b/tools/changelog.sh @@ -114,6 +114,11 @@ function parse-commit { fi } + # Ignore commit if it is a merge commit + if [[ $(command git show -s --format=%p $1 | wc -w) -gt 1 ]]; then + return + fi + # Parse commit with hash $1 local hash="$1" subject body warning rhash subject="$(command git show -s --format=%s $hash)"