10 lines
192 B
Bash
Executable File
10 lines
192 B
Bash
Executable File
#!/bin/sh
|
|
set -eu
|
|
|
|
description=$(git describe --tags --long --match 'v[0-9]*')
|
|
version=${description#v}
|
|
case "$version" in
|
|
*-0-g*) version=${version%%-0-g*} ;;
|
|
esac
|
|
printf '%s\n' "$version"
|