Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'build_files/windows/check_submodules.cmd')
-rw-r--r--build_files/windows/check_submodules.cmd20
1 files changed, 20 insertions, 0 deletions
diff --git a/build_files/windows/check_submodules.cmd b/build_files/windows/check_submodules.cmd
new file mode 100644
index 00000000000..c0c64148dd7
--- /dev/null
+++ b/build_files/windows/check_submodules.cmd
@@ -0,0 +1,20 @@
+if NOT exist "%BLENDER_DIR%/source/tools" (
+ echo Checking out sub-modules
+ if not "%GIT%" == "" (
+ "%GIT%" submodule update --init --recursive --progress
+ if errorlevel 1 goto FAIL
+ "%GIT%" submodule foreach git checkout master
+ if errorlevel 1 goto FAIL
+ "%GIT%" submodule foreach git pull --rebase origin master
+ if errorlevel 1 goto FAIL
+ goto EOF
+ ) else (
+ echo Blender submodules not found, and git not found in path to retrieve them.
+ goto FAIL
+ )
+)
+goto EOF
+
+:FAIL
+exit /b 1
+:EOF \ No newline at end of file