Files
glorytun/version.sh
2015-12-08 15:16:22 +01:00

10 lines
248 B
Bash
Executable File

#!/bin/sh
[ -z "${VERSION}" ] && VERSION=`git describe --tags --always 2>/dev/null` \
&& VERSION=${VERSION#v}
[ -z "${VERSION}" ] && VERSION=`basename \`pwd\`` \
&& VERSION=${VERSION#*-}
printf ${VERSION}