build-deps.cmd: GitCloneAndCheckoutRevision - always checkout the revision, so that users don't have the nuke their existing clones before running the script.

This commit is contained in:
Stinkfist0
2016-02-27 17:44:45 +02:00
parent 7ed219af70
commit 851fadb4ec
+6 -4
View File
@@ -395,15 +395,17 @@ IF NOT EXIST "%2". (
call cecho.cmd 0 13 "Cloning %DEPENDENCY_NAME% into %2."
pushd "%DEPS_DIR%"
call git clone %1 %2
pushd "%2"
call cecho.cmd 0 13 "Checking out %DEPENDENCY_NAME% revision %3."
call git checkout %3
set RET=%ERRORLEVEL%
if not %RET%==0 exit /b %RET%
popd
) ELSE (
call cecho.cmd 0 13 "%DEPENDENCY_NAME% already cloned. Skipping."
call cecho.cmd 0 13 "%DEPENDENCY_NAME% already cloned."
set RET=0
)
pushd "%2"
call cecho.cmd 0 13 "Checking out %DEPENDENCY_NAME% revision %3."
call git checkout %3
set RET=%ERRORLEVEL%
popd
exit /b %RET%