summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-06-21 09:47:28 -0400
committerBrad King <brad.king@kitware.com>2021-06-21 09:47:43 -0400
commitd6c0cc16815e635e8095c68d6239a37d73fe6479 (patch)
treeff40f8d58d89e61d42de337c3bcc5eaf590d8d46
parentacd82e46906cbd53cdce355456e43e224777a4ba (diff)
parent360ff17dc6e3dba2af56b13fa43b246633e13465 (diff)
downloadcmake-d6c0cc16815e635e8095c68d6239a37d73fe6479.tar.gz
Merge branch 'ep-git-update-commit-ref' into release-3.20
Merge-request: !6249
-rw-r--r--Modules/ExternalProject-gitupdate.cmake.in2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/ExternalProject-gitupdate.cmake.in b/Modules/ExternalProject-gitupdate.cmake.in
index 461e323540..0de2372ecf 100644
--- a/Modules/ExternalProject-gitupdate.cmake.in
+++ b/Modules/ExternalProject-gitupdate.cmake.in
@@ -5,7 +5,7 @@ cmake_minimum_required(VERSION 3.5)
function(get_hash_for_ref ref out_var err_var)
execute_process(
- COMMAND "@git_EXECUTABLE@" rev-parse "${ref}^{commit}"
+ COMMAND "@git_EXECUTABLE@" rev-parse "${ref}^0"
WORKING_DIRECTORY "@work_dir@"
RESULT_VARIABLE error_code
OUTPUT_VARIABLE ref_hash