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.
This commit is contained in:
Brad King 2012-06-20 10:14:23 -04:00
parent 30305b989e
commit 5c153c62f3
1 changed files with 3 additions and 0 deletions

View File

@ -90,6 +90,9 @@ ${AUTHOR_CONFIG}")
run_child(WORKING_DIRECTORY ${TOP}/import run_child(WORKING_DIRECTORY ${TOP}/import
COMMAND ${GIT} add . COMMAND ${GIT} add .
) )
run_child(WORKING_DIRECTORY ${TOP}/import
COMMAND ${GIT} config core.safecrlf false
)
run_child(WORKING_DIRECTORY ${TOP}/import run_child(WORKING_DIRECTORY ${TOP}/import
COMMAND ${GIT} submodule add ${MOD_REPO} module COMMAND ${GIT} submodule add ${MOD_REPO} module
) )