From 80c5e9e2c539a7f5b3b12f62d65c466ce1101394 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Sun, 19 Nov 2023 00:14:04 +0100 Subject: [PATCH] Update PyNUTClient.yml Signed-off-by: Jim Klimov --- .github/workflows/PyNUTClient.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/PyNUTClient.yml b/.github/workflows/PyNUTClient.yml index 5e96018bce..29cea51d19 100644 --- a/.github/workflows/PyNUTClient.yml +++ b/.github/workflows/PyNUTClient.yml @@ -42,11 +42,12 @@ jobs: git --version >&2 || true ; TAG_NAME="$(echo $GITHUB_REF | cut -d / -f 3)" ; if [ x"$TAG_NAME" = xmaster ]; then - TAG_NAME="$(git describe --tags --match 'v[0-9]*.[0-9]*.[0-9]' --exclude '*-signed' --exclude '*rc*' --exclude '*alpha*' --exclude '*beta*' 2>/dev/null || git describe --tags --exclude '*rc*' --exclude '*alpha*' --exclude '*beta*' --exclude '*Windows*' --exclude '*IPM*' 2>/dev/null | sed -e 's/^v\([0-9]\)/\1/' -e 's,^.*/,,')" \ + { TAG_NAME="$(git describe --tags --match 'v[0-9]*.[0-9]*.[0-9]' --exclude '*-signed' --exclude '*rc*' --exclude '*alpha*' --exclude '*beta*')" + || TAG_NAME="$(git describe --tags --exclude '*rc*' --exclude '*alpha*' --exclude '*beta*' --exclude '*Windows*' --exclude '*IPM*')" ; } \ && test -n "${TAG_NAME}" \ || TAG_NAME="2.8.1-`TZ=UTC date +%s`" ; fi >&2 ; - TAG_NAME="$(echo "$TAG_NAME" | sed -e 's/^v//' -e 's/-g.*$//' -e 's/-/./g')" ; + TAG_NAME="$(echo "$TAG_NAME" | sed -e 's/^v\([0-9]\)/\1/' -e 's,^.*/,,' -e 's/^v//' -e 's/-g.*$//' -e 's/-/./g')" ; echo "TAG_NAME=$TAG_NAME" >> $GITHUB_OUTPUT - name: Install pypa/setuptools run: >-