Use plain repo tags for build version

This commit is contained in:
Mikhail Chusavitin
2026-04-03 10:48:51 +03:00
parent 11f52ac710
commit 8692f825bc
3 changed files with 2 additions and 19 deletions

View File

@@ -1,15 +1,9 @@
#!/bin/sh
set -eu
tag="$(git describe --tags --match 'audit/v*' --abbrev=7 --dirty 2>/dev/null || true)"
if [ -z "${tag}" ]; then
tag="$(git describe --tags --match 'v[0-9]*' --abbrev=7 --dirty 2>/dev/null || true)"
fi
tag="$(git describe --tags --match 'v[0-9]*' --abbrev=7 --dirty 2>/dev/null || true)"
case "${tag}" in
audit/v*)
printf '%s\n' "${tag#audit/v}"
;;
v*)
printf '%s\n' "${tag#v}"
;;