summaryrefslogtreecommitdiffstats
path: root/Tests/CTestUpdateGIT.cmake.in
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2012-06-20 14:14:23 (GMT)
committerBrad King <brad.king@kitware.com>2012-06-20 14:19:44 (GMT)
commit5c153c62f3780bdc4976a9d25e6b0c217170558e (patch)
tree732e7daea0f25bc7a1ef22cbe05f80aa813b28bd /Tests/CTestUpdateGIT.cmake.in
parent30305b989e944d0b5bdff16ba408d636a8c81e91 (diff)
downloadCMake-5c153c62f3780bdc4976a9d25e6b0c217170558e.zip
CMake-5c153c62f3780bdc4976a9d25e6b0c217170558e.tar.gz
CMake-5c153c62f3780bdc4976a9d25e6b0c217170558e.tar.bz2
Make CTest.UpdateGIT robust to Git safecrlf on Windows
If the user has configured 'core.autocrlf' and 'core.safecrlf' then 'git submodule add' will fail to 'git add' the '.gitmodules' file because it has LF newlines, at least as of Git 1.7.11. Disable 'core.safecrlf' in our test repository to avoid the problem.
Diffstat (limited to 'Tests/CTestUpdateGIT.cmake.in')
-rw-r--r--Tests/CTestUpdateGIT.cmake.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/Tests/CTestUpdateGIT.cmake.in b/Tests/CTestUpdateGIT.cmake.in
index 793b987..eb9f987 100644
--- a/Tests/CTestUpdateGIT.cmake.in
+++ b/Tests/CTestUpdateGIT.cmake.in
@@ -91,6 +91,9 @@ run_child(WORKING_DIRECTORY ${TOP}/import
COMMAND ${GIT} add .
)
run_child(WORKING_DIRECTORY ${TOP}/import
+ COMMAND ${GIT} config core.safecrlf false
+ )
+run_child(WORKING_DIRECTORY ${TOP}/import
COMMAND ${GIT} submodule add ${MOD_REPO} module
)
run_child(WORKING_DIRECTORY ${TOP}/import