Permalink
Browse files

Don't run msys.bat if it is being run from a submodule

  • Loading branch information...
1 parent 70baf56 commit 71d91e6104558d55dc37b5fb3f2ed900260ef084 @tclem tclem committed Jun 12, 2012
Showing with 7 additions and 0 deletions.
  1. +7 −0 msys.bat
View
@@ -12,6 +12,9 @@ rem ember to set the "Start in:" field of the shortcut.
rem A value similar to C:\msys\1.0\bin is what the "Start in:" field needs
rem to represent.
+rem ember to not even start if we are a submodule
+if not exist .git\nul goto failed_submodule
+
rem this should let run MSYS shell on x64
if "%PROCESSOR_ARCHITECTURE%" == "AMD64" (
SET COMSPEC=%WINDIR%\SysWOW64\cmd.exe
@@ -57,6 +60,10 @@ set BIN="%~dp0bin\"
if EXIST %BIN%bash.exe goto startbash
if EXIST %BIN%rxvt.exe goto startrxvt
+:failed_submodule
+echo You cannot run this in a submodule, please make a fresh clone of msysgit.
+goto EOF
+
:failed
echo Cannot find the rxvt.exe or bash.exe binary -- aborting.
pause

0 comments on commit 71d91e6

Please sign in to comment.