mirror of
https://github.com/cincheo/jsweet.git
synced 2025-12-15 15:29:22 +00:00
improved error reporting when JDK home is not defined
This commit is contained in:
parent
43e58e6b57
commit
4b3fcff2e6
@ -78,6 +78,9 @@ public class JSweetCommandLineLauncher {
|
||||
String classPath = jsapArgs.getString("classpath");
|
||||
logger.info("classpath: " + classPath);
|
||||
|
||||
ErrorCountTranspilationHandler transpilationHandler = new ErrorCountTranspilationHandler(new ConsoleTranspilationHandler());
|
||||
|
||||
try {
|
||||
File tsOutputDir = jsapArgs.getFile("tsout");
|
||||
tsOutputDir.mkdirs();
|
||||
logger.info("ts output dir: " + tsOutputDir);
|
||||
@ -95,8 +98,6 @@ public class JSweetCommandLineLauncher {
|
||||
LinkedList<File> files = new LinkedList<File>();
|
||||
Util.addFiles(".java", inputDir, files);
|
||||
|
||||
ErrorCountTranspilationHandler transpilationHandler = new ErrorCountTranspilationHandler(new ConsoleTranspilationHandler());
|
||||
try {
|
||||
JSweetTranspiler transpiler = new JSweetTranspiler(tsOutputDir, jsOutputDir, classPath);
|
||||
|
||||
transpiler.setBundle(jsapArgs.getBoolean("bundle"));
|
||||
@ -256,8 +257,7 @@ public class JSweetCommandLineLauncher {
|
||||
// Ignore assertions
|
||||
switchArg = new Switch("ignoreAssertions");
|
||||
switchArg.setLongFlag("ignoreAssertions");
|
||||
switchArg.setHelp(
|
||||
"Set the transpiler to ignore 'assert' statements, i.e. no code is generated for assertions.");
|
||||
switchArg.setHelp("Set the transpiler to ignore 'assert' statements, i.e. no code is generated for assertions.");
|
||||
switchArg.setDefault("false");
|
||||
jsap.registerParameter(switchArg);
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user