diff --git a/bin/spack.bat b/bin/spack.bat index 495b61a794..073f778c34 100644 --- a/bin/spack.bat +++ b/bin/spack.bat @@ -83,6 +83,16 @@ if defined _sp_flags ( exit /B 0 ) ) +if not defined _sp_subcommand ( + if not defined _sp_args ( + if not defined _sp_flags ( + python "%spack%" --help + exit /B 0 + ) + ) +) + + :: pass parsed variables outside of local scope. Need to do :: this because delayedexpansion can only be set by setlocal echo %_sp_flags%>flags @@ -92,24 +102,24 @@ endlocal set /p _sp_subcommand=