Git complains "fatal: No tags can describe '757ebfcc2f9d54dec5f1a008d72bcfa41fc88ca7'" because the repo has no tags. Use --always to give the hash in that case.

This commit is contained in:
Uli Kusterer 2017-01-10 16:05:53 +01:00
parent 757ebfcc2f
commit aa17a5d07a

View File

@ -24,7 +24,7 @@ INFO_STRINGS="${TARGET_BUILD_DIR}/${INFOSTRINGS_PATH}"
BUILD_VERSION=$(git describe --tags --always --dirty=+)
# Use the latest tag for short version (expected tag format "n[.n[.n]]")
LATEST_TAG=$(git describe --tags --abbrev=0)
LATEST_TAG=$(git describe --tags --always --abbrev=0)
COMMIT_COUNT_SINCE_TAG=$(git rev-list --count ${LATEST_TAG}..)
if [ $LATEST_TAG = "start" ]
then LATEST_TAG=0