Add: Detect stable tags automatically, and set the 'stable' flag in '_openttd_newgrf_version' accordingly. (#7317)

This commit is contained in:
frosch
2019-03-03 20:08:28 +01:00
committed by GitHub
parent 8016b8b3e9
commit 39cda89e85
4 changed files with 31 additions and 10 deletions

View File

@@ -83,9 +83,15 @@ if [ -d "$ROOT_DIR/.git" ]; then
if [ -n "$TAG" ]; then
VERSION="${TAG}"
ISTAG="1"
if [ -n "`echo \"${TAG}\" | grep \"^[0-9.]*$\"`" ]; then
ISSTABLETAG="1"
else
ISSTABLETAG="0"
fi
else
VERSION="${ISODATE}-${BRANCH}${hashprefix}${SHORTHASH}"
ISTAG="0"
ISSTABLETAG="0"
fi
elif [ -f "$ROOT_DIR/.ottdrev" ]; then
@@ -102,6 +108,7 @@ else
TAG=""
VERSION=""
ISTAG="0"
ISSTABLETAG="0"
fi
echo "$VERSION $ISODATE $MODIFIED $HASH $ISTAG"
echo "$VERSION $ISODATE $MODIFIED $HASH $ISTAG $ISSTABLETAG"