Maven - Prefix (Plugin Alias)

Card Puncher Data Processing

About

A prefix is a named alias for a plugin.

Management

Setting a prefix to a goal

Automatic

The prefix assignation is done automatically if the plugin naming convention is used:

  • prefix-maven-plugin
  • or maven-prefix-plugin (if the plugin is part of the Apache Maven project).

with the goal-prefix configuration

Example of prefix configuration in the pom.xml

<plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-plugin-plugin</artifactId>
	<version>3.4</version>
	<configuration>
		<goalPrefix>hello</goalPrefix>
	</configuration>
........
</plugin>

Execution of a goal with a plugin prefix

<code dos>
mvn prefix:goal@executionId

Documentation / Reference





Discover More
Card Puncher Data Processing
Maven - Goal

A goal is the execution part of a plugin. An individual plugin may have multiple goals. Each goal may have a separate configuration. If you are familiar with Ant, a goal is similar to a task. A goal...
Maven Execution Id
Maven - Plugin Execution

A plugin execution where: where: executionId see Default ??? default in the POM model default-cli from the command line default-goalName mojo bound to the build lifecycle...



Share this page:
Follow us:
Task Runner