aboutsummaryrefslogtreecommitdiff
path: root/cmake/GenVersion.cmake
diff options
context:
space:
mode:
authorHoward Chu <hyc@symas.com>2019-06-12 15:16:17 +0100
committerHoward Chu <hyc@symas.com>2019-06-12 16:47:33 +0100
commit1dc4ebfd6c9070a66e4617929c3d19d3b8cbe52c (patch)
treebb43c117e116b1bf9ae95f46063864b75f220532 /cmake/GenVersion.cmake
parentDelete redundant cppzmq dependency (diff)
downloadmonero-1dc4ebfd6c9070a66e4617929c3d19d3b8cbe52c.tar.xz
Use 9 digit build IDs
Diffstat (limited to 'cmake/GenVersion.cmake')
-rw-r--r--cmake/GenVersion.cmake3
1 files changed, 2 insertions, 1 deletions
diff --git a/cmake/GenVersion.cmake b/cmake/GenVersion.cmake
index 1ea5b209c..b2ccfbc34 100644
--- a/cmake/GenVersion.cmake
+++ b/cmake/GenVersion.cmake
@@ -29,7 +29,7 @@
# Parts of this file are originally copyright (c) 2012-2013 The Cryptonote developers
# Check what commit we're on
-execute_process(COMMAND "${GIT}" rev-parse --short HEAD RESULT_VARIABLE RET OUTPUT_VARIABLE COMMIT OUTPUT_STRIP_TRAILING_WHITESPACE)
+execute_process(COMMAND "${GIT}" rev-parse --short=9 HEAD RESULT_VARIABLE RET OUTPUT_VARIABLE COMMIT OUTPUT_STRIP_TRAILING_WHITESPACE)
if(RET)
# Something went wrong, set the version tag to -unknown
@@ -38,6 +38,7 @@ if(RET)
set(VERSIONTAG "unknown")
configure_file("src/version.cpp.in" "${TO}")
else()
+ string(SUBSTRING ${COMMIT} 0 9 COMMIT)
message(STATUS "You are currently on commit ${COMMIT}")
# Get all the tags