findversion.sh: Handle YEAR part of .ottdrev-vc

pull/174/head
Jonathan G Rennison 4 years ago
parent 212f6f4dcb
commit 47a55afe6d

@ -101,12 +101,16 @@ elif [ -f "$ROOT_DIR/.ottdrev-vc" ]; then
HASH="`echo "$VERSION_DATA" | cut -f 4 -d' '`"
ISTAG="`echo "$VERSION_DATA" | cut -f 5 -d' '`"
ISSTABLETAG="`echo "$VERSION_DATA" | cut -f 6 -d' '`"
YEAR="`echo "$VERSION_DATA" | cut -f 7 -d' '`"
if [ -z "$ISTAG" ]; then
ISTAG="0"
fi
if [ -z "$ISSTABLETAG" ]; then
ISSTABLETAG="0"
fi
if [ -z "$YEAR" ]; then
YEAR=`echo ${ISODATE} | cut -c1-4`
fi
if [ "$MODIFIED" = "2" ]; then
VERSION="`echo "$VERSION" | sed -e 's/M$//'`"
fi

Loading…
Cancel
Save