summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2015-04-07 10:48:31 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-04-08 14:15:42 -0700
commit20c1907adbc96eae5966b88c5512f757a45dda14 (patch)
treef5f07e9f595f035852d16ffdaa61589de7207475 /scripts
parentdc47003e5b183fafd5e0052f530a6bc44ca451fb (diff)
downloadsubsurface-20c1907adbc96eae5966b88c5512f757a45dda14.tar.gz
When building from tar file, check .gitversion to get the correct version
Distribution builds on Linux tend to be made from tar files, not from git trees. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/get-version2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/get-version b/scripts/get-version
index eb93a3322..27f02f640 100755
--- a/scripts/get-version
+++ b/scripts/get-version
@@ -19,7 +19,7 @@ if [ $# -eq 2 ] && [ "$2" ]; then
v0=$2
else
cmd="git describe --tags --abbrev=12"
- v0=$($cmd) || croak "odd; command '$cmd' failed"
+ v0=$($cmd) || v0=$(cat .gitversion) || croak "odd; command '$cmd' failed"
fi
# strip off the 'v' prefix, if any