PluginMetadata

Plugin descriptor metadata for using with script-based mojos.

<pluginMetadata xmlns="http://maven.apache.org/PLUGIN-METADATA/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/PLUGIN-METADATA/1.1.0 http://maven.apache.org/xsd/plugin-metadata-1.1.0.xsd">
  <mojos>
    <mojo>
      <goal/>
      <phase/>
      <aggregator/>
      <requiresDependencyResolution/>
      <requiresProject/>
      <requiresReports/>
      <requiresOnline/>
      <inheritByDefault/>
      <requiresDirectInvocation/>
      <execution>
        <lifecycle/>
        <phase/>
        <goal/>
      </execution>
      <components>
        <component>
          <role/>
          <hint/>
        </component>
      </components>
      <parameters>
        <parameter>
          <name/>
          <alias/>
          <property/>
          <required/>
          <readonly/>
          <expression/>
          <defaultValue/>
          <type/>
          <description/>
          <deprecated/>
          <since/>
        </parameter>
      </parameters>
      <description/>
      <deprecated/>
      <since/>
      <call/>
    </mojo>
  </mojos>
</pluginMetadata>

pluginMetadata

Root element of a script-based mojo's plugin metadata bindings.

Element Type Since Description
mojos/mojo* List<Mojo> (Many) The list of mojos contained in the accompanying script.

mojo

Mojo descriptor definition.

Element Type Since Description
goal String The name of the goal used to invoke this mojo.
phase String The phase to which this mojo should be bound by default.
aggregator boolean Whether this mojo operates as an aggregator when the reactor is run. That is, only runs once.

Default value is: false

.
requiresDependencyResolution String The scope of dependencies that this mojo requires to have resolved.
requiresProject boolean Whether this mojo requires a project instance in order to execute.

Default value is: false

.
requiresReports boolean Whether this mojo requires a reports section in the POM.

Default value is: false

.
requiresOnline boolean Whether this mojo requires online mode to operate normally.

Default value is: false

.
inheritByDefault boolean Whether this mojo's configuration should propagate down the POM inheritance chain by default.

Default value is: false

.
requiresDirectInvocation boolean If true, this mojo can only be directly invoked (eg. specified directly on the command line).

Default value is: false

.
execution LifecycleExecution Information about a sub-execution of the Maven lifecycle which should be processed.
components/component* List<Component> (Many) List of plexus components required by this mojo.
parameters/parameter* List<Parameter> (Many) List of parameters used by this mojo.
description String The description for this parameter.
deprecated String A deprecation message for this mojo parameter.
since String 1.1.0 Version when the mojo was added to the API.
call String The target/method within the script to call when this mojo executes.

execution

A sub-process execution of a lifecycle to satisfy the needs of a mojo.

Element Type Since Description
lifecycle String The name of the overlay to apply to the sub-lifecycle before executing it. If specified, this lifecycle overlay definition will be bundled with the plugin.
phase String The phase in the sub-lifecycle.
goal String A goal, not attached to a lifecycle phase, which should be executed ahead of this mojo.

component

A reference to a plexus component, assumed to be available to the plugin container.

Element Type Since Description
role String The component role to lookup.
hint String The role-hint to lookup.

parameter

A parameter used by a mojo, and configurable from the command line or POM configuration sections.

Element Type Since Description
name String The parameter name
alias String An alternate name for the parameter.
property String The JavaBeans property name to use to configure the mojo with this parameter.
required boolean Whether this parameter is required.

Default value is: false

.
readonly boolean Whether this parameter can be directly edited. If false, this param is either derived from another POM element, or refers to a runtime instance of the build system.

Default value is: false

.
expression String The command-line reference to this parameter.
defaultValue String An expression in the form ${instance.property} for extracting a value for this parameter, especially from a runtime instance within the build system. (eg. ${project.build.directory} references project.getBuild().getDirectory())
type String The java type for this parameter.
description String The description for this parameter.
deprecated String A deprecation message for this mojo parameter.
since String 1.1.0 Version when the parameter was added.