From 26251849c6503486d337354b8e0a4d6a562220ea Mon Sep 17 00:00:00 2001 From: o9000 Date: Sun, 26 Nov 2017 18:38:17 +0100 Subject: [PATCH] Include also timestamp in version number for unstable builds, so that version numbers increase --- get_version.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/get_version.sh b/get_version.sh index 2e78037..473c9f0 100755 --- a/get_version.sh +++ b/get_version.sh @@ -41,8 +41,8 @@ then if [ "$VERSION" = "master" ] then PREVIOUS=$(grep '^2' "${SCRIPT_DIR}/ChangeLog" | head -n 2 | tail -n 1 | cut -d ' ' -f 2) - HASH=$(git log -n 1 --pretty=format:"%h" 2>/dev/null) - VERSION=$PREVIOUS-next-g$HASH + HASH=$(git log -n 1 --pretty=format:%cI.%ct.%h | tr -d ':' | tr -d '-' | tr '.' '-' | sed 's/T[0-9\+]*//g' 2>/dev/null) + VERSION=$PREVIOUS-next-$HASH fi fi fi