summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2015-10-13 17:51:00 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2015-10-13 17:51:00 (GMT)
commitd6af5566e8c07b6b47ac78b1652c29dbe0e31aa2 (patch)
tree786ad4ead3bb1af7595c5450cb06dc39de51b12b
parentfc04b8f4b8ebb53b19c0430ac992baa46c75d2e9 (diff)
parent57f701a7f045fc13807933860bad22fa405c6621 (diff)
downloadCMake-d6af5566e8c07b6b47ac78b1652c29dbe0e31aa2.zip
CMake-d6af5566e8c07b6b47ac78b1652c29dbe0e31aa2.tar.gz
CMake-d6af5566e8c07b6b47ac78b1652c29dbe0e31aa2.tar.bz2
Merge topic 'FindGit-Atlassian-SourceTree'
57f701a7 FindGit: Search in 'Atlassian SourceTree' user directory (#15758)
-rw-r--r--Modules/FindGit.cmake6
1 files changed, 5 insertions, 1 deletions
diff --git a/Modules/FindGit.cmake b/Modules/FindGit.cmake
index b4f7b4b..2c3e5fd 100644
--- a/Modules/FindGit.cmake
+++ b/Modules/FindGit.cmake
@@ -48,17 +48,21 @@ if(WIN32)
# GitHub search path for Windows
set(github_path "$ENV{LOCALAPPDATA}/Github/PortableGit*/bin")
file(GLOB github_path "${github_path}")
+ # SourceTree search path for Windows
+ set(_git_sourcetree_path "$ENV{LOCALAPPDATA}/Atlassian/SourceTree/git_local/bin")
endif()
endif()
find_program(GIT_EXECUTABLE
NAMES ${git_names}
- PATHS ${github_path}
+ PATHS ${github_path} ${_git_sourcetree_path}
PATH_SUFFIXES Git/cmd Git/bin
DOC "git command line client"
)
mark_as_advanced(GIT_EXECUTABLE)
+unset(_git_sourcetree_path)
+
if(GIT_EXECUTABLE)
execute_process(COMMAND ${GIT_EXECUTABLE} --version
OUTPUT_VARIABLE git_version