Merge "Show version tag when building" into kitkat

This commit is contained in:
Curtis Mayers 2014-01-21 22:03:40 -05:00 committed by Gerrit Code Review
commit 299a567c0a
1 changed files with 6 additions and 1 deletions

View File

@ -43,8 +43,13 @@ EXTRAS="$2"
MAJOR=$(cat $DIR/vendor/pa/vendor.mk | grep 'ROM_VERSION_MAJOR := *' | sed 's/ROM_VERSION_MAJOR := //g')
MINOR=$(cat $DIR/vendor/pa/vendor.mk | grep 'ROM_VERSION_MINOR := *' | sed 's/ROM_VERSION_MINOR := //g')
MAINTENANCE=$(cat $DIR/vendor/pa/vendor.mk | grep 'ROM_VERSION_MAINTENANCE := *' | sed 's/ROM_VERSION_MAINTENANCE := //g')
TAG=$(cat $DIR/vendor/pa/vendor.mk | grep 'ROM_VERSION_TAG := *' | sed 's/ROM_VERSION_TAG := //g')
VERSION=$MAJOR.$MINOR$MAINTENANCE
if [ -n "$TAG" ]; then
VERSION=$MAJOR.$MINOR$MAINTENANCE-$TAG
else
VERSION=$MAJOR.$MINOR$MAINTENANCE
fi
# If there is no extra parameter, reduce parameters index by 1
if [ "$EXTRAS" == "true" ] || [ "$EXTRAS" == "false" ]; then