From 94a9e07c0af14b9c94d1711711155d9ec0167ba4 Mon Sep 17 00:00:00 2001 From: Magnus Jacobsson Date: Tue, 7 Sep 2021 19:44:57 +0200 Subject: [PATCH] ci/build.sh: remove trailing text after actual version ID Fixes a problem on Cygwin where 'uname -r' gives: 3.2.0(0.340/5/3) which, when used as the name of a directory, actually represents a directory named '3.2.0(0.340', containing a subdirectory named '5' containing a subdirectory named '3)'. --- ci/build.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ci/build.sh b/ci/build.sh index 3c8e9eef8..93dacf059 100755 --- a/ci/build.sh +++ b/ci/build.sh @@ -14,7 +14,8 @@ if [ -f /etc/os-release ]; then fi else ID=$( uname -s ) - VERSION_ID=$( uname -r ) + # remove trailing text after actual version + VERSION_ID=$( uname -r | sed "s/\([0-9\.]*\).*/\1/") fi COLLECTION=$( cat COLLECTION ) META_DATA_DIR=Metadata/${COLLECTION}/${ID}/${VERSION_ID} -- 2.49.0