diff --git a/launcher-package/src/universal/bin/sbt.bat b/launcher-package/src/universal/bin/sbt.bat index 4a03a92bb..3aedafe24 100755 --- a/launcher-package/src/universal/bin/sbt.bat +++ b/launcher-package/src/universal/bin/sbt.bat @@ -729,6 +729,21 @@ if !sbt_args_print_sbt_version! equ 1 ( goto :eof ) +rem Handle --version here (after native client check is skipped) for sbt 2.x project dirs (#8717) +:skip_native_for_version +if "!sbt_args_print_version!" == "1" ( + if "!is_this_dir_sbt!" == "1" ( + if not "!build_props_sbt_version!" == "" ( + echo sbt version in this project: !build_props_sbt_version! + ) + ) + echo sbt runner version: !init_sbt_version! + echo. + echo [info] sbt runner (sbt-the-batch-script) is a runner to run any declared version of sbt. + echo [info] Actual version of the sbt is declared using project\build.properties for each build. + goto :eof +) + if defined sbt_args_verbose ( echo # Executing command line: echo "!_JAVACMD!"