]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
SCRIPTS: update create-release to fix the changelog on new branches
authorWilly Tarreau <w@1wt.eu>
Mon, 25 Nov 2019 19:40:52 +0000 (20:40 +0100)
committerWilly Tarreau <w@1wt.eu>
Mon, 25 Nov 2019 19:40:52 +0000 (20:40 +0100)
The changelog is empty when creating a dev0 version and this confuses
the commit message, let's clearly mention the exact copy when there are
no changes.

scripts/create-release

index fe6c802e61539cfde6a8ba5340e285d4081fa53e..8a8e05d69fc9e80f7fa6b39b38b5a27fd80d7614 100755 (executable)
@@ -164,7 +164,11 @@ echo "Updating CHANGELOG ..."
   echo
   echo "$DATE : $NEW"
   #git shortlog v$OLD.. | sed -ne 's/^      /    - /p'
-  git log --oneline --reverse --format="    - %s" v$OLD..
+  if [ $(git log --oneline v$OLD.. | wc -l) = 0 ]; then
+    echo "    - exact copy of $OLD"
+  else
+    git log --oneline --reverse --format="    - %s" v$OLD..
+  fi
   echo
   tail -n +4 CHANGELOG
 ) >.chglog.tmp && mv .chglog.tmp CHANGELOG