From d65c6fdbe4c0f41a3e4da75f520e0739ec0fb25b Mon Sep 17 00:00:00 2001 From: Jonathan Wright <8390543+jonathanspw@users.noreply.github.com> Date: Mon, 29 Apr 2024 13:40:04 -0500 Subject: [PATCH] Expand to work with directory structure of CI tarballs --- scripts/version | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/version b/scripts/version index d9204cd1be..91050c350e 100755 --- a/scripts/version +++ b/scripts/version @@ -11,8 +11,8 @@ if test -d .git; then commit=$(git describe --always --dirty) echo "${branch}-${commit}" fi -elif [[ "$(basename $(pwd))" =~ ^jq-jq-([0-9]+\.[0-9]+(\.[0-9]+)?)$ ]]; then - echo ${BASH_REMATCH[1]} +elif [[ "$(basename $(pwd))" =~ ^jq-(jq-)?([0-9]+\.[0-9]+(\.[0-9]+)?)$ ]]; then + echo ${BASH_REMATCH[2]} else exit 1 fi