[MJLINK-18] Added option for generating jlink launcher.
diff --git a/src/main/java/org/apache/maven/plugins/jlink/JLinkMojo.java b/src/main/java/org/apache/maven/plugins/jlink/JLinkMojo.java
index 4261f1d..ccc82a6 100644
--- a/src/main/java/org/apache/maven/plugins/jlink/JLinkMojo.java
+++ b/src/main/java/org/apache/maven/plugins/jlink/JLinkMojo.java
@@ -93,6 +93,14 @@
private Integer compress;
/**
+ * Should the plugin generate a launcher script by means of jlink? The command line equivalent is:
+ * <code>--launcher <name>=<module>[/<mainclass>]</code>. The valid values for the level are:
+ * <code><name>=<module>[/<mainclass>]</code>.
+ */
+ @Parameter
+ private String launcher;
+
+ /**
* Limit the universe of observable modules. The following gives an example of the configuration which can be used
* in the <code>pom.xml</code> file.
*
@@ -496,6 +504,11 @@
argsFile.println( "--compress" );
argsFile.println( compress );
}
+ if ( launcher != null )
+ {
+ argsFile.println( "--launcher" );
+ argsFile.println( launcher );
+ }
if ( disablePlugin != null )
{