1
0
Fork 0
mirror of https://github.com/ethauvin/kobalt.git synced 2025-04-26 08:27:12 -07:00

Launch the wrapper last.

This commit is contained in:
Cedric Beust 2016-02-18 06:46:13 +04:00
parent 1f53aabe50
commit a6a279f71a

View file

@ -153,8 +153,10 @@ private class Main @Inject constructor(
// --init: create a new build project and install the wrapper
// Make sure the wrapper won't call us back with --noLaunch
//
com.beust.kobalt.wrapper.Main.main(arrayOf("--noLaunch") + argv)
projectGenerator.run(args, pluginClassLoader)
// The wrapper has to call System.exit() in order to set the exit code,
// so make sure we call it last (or possibly launch it in a separate JVM).
com.beust.kobalt.wrapper.Main.main(arrayOf("--noLaunch") + argv)
} else if (args.usage) {
jc.usage()
} else if (args.serverMode) {