From 0fa627dda8b6362c11879c619291875f3f739019 Mon Sep 17 00:00:00 2001 From: Karlson2k Date: Mon, 4 Apr 2016 18:56:12 +0300 Subject: [PATCH] .bat-files: exit only from .bat file instead of terminating parent command processor, bypass result of "start" to calling process --- filesystem/mingw32_shell.bat | 6 +++--- filesystem/mingw64_shell.bat | 6 +++--- filesystem/msys2_shell.bat | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/filesystem/mingw32_shell.bat b/filesystem/mingw32_shell.bat index b294c828..3e1b23bf 100644 --- a/filesystem/mingw32_shell.bat +++ b/filesystem/mingw32_shell.bat @@ -43,15 +43,15 @@ if "x%MSYSCON%" == "xconsole.exe" goto startconsolez :startmintty if NOT EXIST %WD%mintty.exe goto startsh start %WD%mintty -i /msys2.ico /usr/bin/bash --login %* -exit +exit /b %ERRORLEVEL% :startconsolez cd %WD%..\lib\ConsoleZ start console -t "MinGW" -r "%*" -exit +exit /b %ERRORLEVEL% :startsh start %WD%sh --login -i %* -exit +exit /b %ERRORLEVEL% :EOF diff --git a/filesystem/mingw64_shell.bat b/filesystem/mingw64_shell.bat index 6f6f26f2..6c9ba3fc 100644 --- a/filesystem/mingw64_shell.bat +++ b/filesystem/mingw64_shell.bat @@ -43,15 +43,15 @@ if "x%MSYSCON%" == "xconsole.exe" goto startconsolez :startmintty if NOT EXIST %WD%mintty.exe goto startsh start %WD%mintty -i /msys2.ico /usr/bin/bash --login %* -exit +exit /b %ERRORLEVEL% :startconsolez cd %WD%..\lib\ConsoleZ start console -t "MinGW" -r "%*" -exit +exit /b %ERRORLEVEL% :startsh start %WD%sh --login -i %* -exit +exit /b %ERRORLEVEL% :EOF diff --git a/filesystem/msys2_shell.bat b/filesystem/msys2_shell.bat index 38ce860e..93610bc4 100644 --- a/filesystem/msys2_shell.bat +++ b/filesystem/msys2_shell.bat @@ -43,15 +43,15 @@ if "x%MSYSCON%" == "xconsole.exe" goto startconsolez :startmintty if NOT EXIST %WD%mintty.exe goto startsh start %WD%mintty -i /msys2.ico /usr/bin/bash --login %* -exit +exit /b %ERRORLEVEL% :startconsolez cd %WD%..\lib\ConsoleZ start console -t "MSys2" -r "%*" -exit +exit /b %ERRORLEVEL% :startsh start %WD%sh --login -i %* -exit +exit /b %ERRORLEVEL% :EOF