From e4c3d87ba6dab118c2b98e7083c45f2e999de929 Mon Sep 17 00:00:00 2001 From: Marius Date: Fri, 11 Nov 2016 21:56:38 +0100 Subject: [PATCH] Use current branch name or tag name when building binaries --- .scripts/build_funcs.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.scripts/build_funcs.sh b/.scripts/build_funcs.sh index 67ee1fe..ac87f8a 100755 --- a/.scripts/build_funcs.sh +++ b/.scripts/build_funcs.sh @@ -2,8 +2,8 @@ set -e -version=$(git rev-parse --abbrev-ref HEAD) -commit=$(git log --format="%H" -n 1) +version="$(git symbolic-ref -q --short HEAD || git describe --tags --exact-match)" +commit="$(git log --format="%H" -n 1)" function compile { local os=$1