summaryrefslogtreecommitdiffstats
path: root/Source/CMakeVersion.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-07-25 12:23:11 (GMT)
committerBrad King <brad.king@kitware.com>2019-07-29 15:25:43 (GMT)
commite1e7986c00912a89b644ff60a8e63189f8ba1ac5 (patch)
tree99f38feccf4bec42a35c732ebf5f60df7336e82c /Source/CMakeVersion.cmake
parent564bcb4cb3fa8182308d3501b9b98aee1bf837d1 (diff)
downloadCMake-e1e7986c00912a89b644ff60a8e63189f8ba1ac5.zip
CMake-e1e7986c00912a89b644ff60a8e63189f8ba1ac5.tar.gz
CMake-e1e7986c00912a89b644ff60a8e63189f8ba1ac5.tar.bz2
CMakeVersion: Consider Git even with just a `.git` file
Diffstat (limited to 'Source/CMakeVersion.cmake')
-rw-r--r--Source/CMakeVersion.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake
index e406b4c..02cf748 100644
--- a/Source/CMakeVersion.cmake
+++ b/Source/CMakeVersion.cmake
@@ -14,7 +14,7 @@ else()
set(CMake_VERSION_IS_RELEASE 0)
# Try to identify the current development source version.
set(CMake_VERSION_SOURCE "")
- if(EXISTS ${CMake_SOURCE_DIR}/.git/HEAD)
+ if(EXISTS ${CMake_SOURCE_DIR}/.git)
find_program(GIT_EXECUTABLE NAMES git git.cmd)
mark_as_advanced(GIT_EXECUTABLE)
if(GIT_EXECUTABLE)