Add release and showWarnings options
@@ -830,6 +830,13 @@ public class DevMojo extends StartDebugMojoSupport {
Xpp3Dom configuration = ExecuteMojoUtil.getPluginGoalConfig(plugin, "compile", log);
JavaCompilerOptions compilerOptions = new JavaCompilerOptions();
+ String showWarnings = getCompilerOption(configuration, "showWarnings", "maven.compiler.showWarnings");
+ if (showWarnings != null) {
+ boolean showWarningsBoolean = Boolean.parseBoolean(showWarnings);
+ log.debug("Setting showWarnings to " + showWarningsBoolean);
+ compilerOptions.setShowWarnings(showWarningsBoolean);
+ }
+
String source = getCompilerOption(configuration, "source", "maven.compiler.source");
if (source != null) {
log.debug("Setting compiler source to " + source);
@@ -842,6 +849,12 @@ public class DevMojo extends StartDebugMojoSupport {
compilerOptions.setTarget(target);
}
+ String release = getCompilerOption(configuration, "release", "maven.compiler.release");
+ if (release != null) {
+ log.debug("Setting compiler release to " + release);
+ compilerOptions.setRelease(release);
+ }
+
return compilerOptions;
}
