From 36d3fef513f4d0ac9d9a4d0dd443af43f08f832d Mon Sep 17 00:00:00 2001 From: michalskrivanek Date: Wed, 9 Nov 2022 09:40:20 +0100 Subject: [PATCH] build: fix return code when SUFFIX is empty we run with bash -e, need to make sure all return codes are 0. --- .automation/build-srpm.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.automation/build-srpm.sh b/.automation/build-srpm.sh index 972effc76a4..9bbad31b273 100755 --- a/.automation/build-srpm.sh +++ b/.automation/build-srpm.sh @@ -2,7 +2,7 @@ # git hash of current commit passed from GitHub or HEAD GIT_HASH=$(git rev-parse --short ${GITHUB_SHA:-HEAD}) -SUFFIX=$(grep -E "]' '/version/{print $3}' | grep -q -- -SNAPSHOT && echo .git${GIT_HASH}) +SUFFIX=$(grep -E "]' '/version/{print $3}' | grep -q -- -SNAPSHOT && echo .git${GIT_HASH} || :) # Directory, where build artifacts will be stored, should be passed as the 1st parameter ARTIFACTS_DIR=${1:-exported-artifacts}