Merge branch 'cpp-11' into save_ext

# Conflicts:
#	src/saveload/saveload.cpp
#	src/saveload/saveload.h
This commit is contained in:
Jonathan G Rennison
2019-02-04 18:24:38 +00:00
280 changed files with 11624 additions and 3855 deletions

View File

@@ -67,20 +67,25 @@ if [ -d "$ROOT_DIR/.git" ]; then
MODIFIED="2"
fi
HASH=`LC_ALL=C git rev-parse --verify HEAD 2>/dev/null`
SHORTHASH=`echo ${HASH} | cut -c1-8`
SHORTHASH=`echo ${HASH} | cut -c1-10`
ISODATE=`LC_ALL=C git show -s --pretty='format:%ci' HEAD | "$AWK" '{ gsub("-", "", $1); print $1 }'`
BRANCH="`git symbolic-ref -q HEAD 2>/dev/null | sed 's@.*/@@'`"
TAG="`git describe --tags 2>/dev/null`"
if [ "$MODIFIED" -eq "0" ]; then
hashprefix="-g"
elif [ "$MODIFIED" -eq "2" ]; then
hashprefix="-m"
else
hashprefix="-u"
fi
if [ -n "$TAG" ]; then
VERSION="${TAG}"
else
VERSION="${ISODATE}-${BRANCH}-g${SHORTHASH}"
VERSION="${ISODATE}-${BRANCH}${hashprefix}${SHORTHASH}"
fi
if [ "$MODIFIED" -eq "2" ]; then
VERSION="${VERSION}M"
fi
elif [ -f "$ROOT_DIR/.ottdrev" ]; then
# We are an exported source bundle
cat $ROOT_DIR/.ottdrev