From 1eadc0136dab1d004e588260008a1273c130790a Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Tue, 18 Jan 2022 22:06:56 +0100 Subject: [PATCH] Fix .dmg naming yet again; sed was breaking the $? check. --- platform/osx/make_dmg.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/platform/osx/make_dmg.sh b/platform/osx/make_dmg.sh index faf42e635..18ca029f5 100644 --- a/platform/osx/make_dmg.sh +++ b/platform/osx/make_dmg.sh @@ -8,8 +8,10 @@ SYNTAX="make_dmg.sh # were found. # Use a tag if what we've built is exactly on one -version=$(git describe --tags --abbrev=0 --match=v2.*.* --exact-match 2> /dev/null | sed -e "s/^v//") -if [ "$?" != "0" ]; then +version=$(git describe --tags --abbrev=0 --match=v2.*.* --exact-match 2> /dev/null) +if [ "$?" == "0" ]; then + version=$(echo $version | sed -e "s/^v//") +else # Otherwise use - version="$(basename $(git name-rev --name-only HEAD))-$(git rev-parse --short HEAD)" fi -- 2.30.2