diff --git a/vendor/init.bat b/vendor/init.bat index dce5d01..6d43398 100644 --- a/vendor/init.bat +++ b/vendor/init.bat @@ -11,7 +11,11 @@ if not defined verbose-output ( set verbose-output=0 ) :: Find root dir if not defined CMDER_ROOT ( - for /f "delims=" %%i in ("%ConEmuDir%\..\..") do set "CMDER_ROOT=%%~fi" + if defined ConEmuDir ( + for /f "delims=" %%i in ("%ConEmuDir%\..\..") do set "CMDER_ROOT=%%~fi" + ) else ( + for /f "delims=" %%i in ("%~dp0\..") do set "CMDER_ROOT=%%~fi" + ) ) :: Remove trailing '\'