Maven plugin¶
Maven plugin is a plugin that simplifies building and packaging Jars for projects that use the Maven (mvn) tooling. It is equivalent to running the following command:
mvn package
The maven-parameters key passes arguments to the mvn package command. The
parameter can also configure any command-line arguments. All values are passed after the
initial package command, delimited by spaces.
The maven-use-wrapper key leverages Maven wrapper files provided by the project to
run the package command. It replaces the default Maven executable with the project’s
mvnw file, to where the package command becomes ./mvnw package.
After a successful build, this plugin will:
Create
bin/andjar/directories in$CRAFT_PART_INSTALL.Find the
javaexecutable provided by the part and link it as$CRAFT_PART_INSTALL/bin/java.Hard link the
.jarfiles generated in$CRAFT_PART_BUILDto$CRAFT_PART_INSTALL/jar.
Keys¶
This plugin provides the following unique keys.
maven-parameters¶
Type: list of strings
Used