Skip to content
Commits on Source (3)
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
asfMavenTlpPlgnBuild()
......@@ -23,13 +23,13 @@
<parent>
<artifactId>maven-plugin-tools</artifactId>
<groupId>org.apache.maven.plugin-tools</groupId>
<version>3.5</version>
<version>3.6.0</version>
</parent>
<artifactId>maven-plugin-annotations</artifactId>
<name>Maven Plugin Tools Java 5 Annotations</name>
<description>Java 5 annotations to use in Mojos</description>
<name>Maven Plugin Tools Java Annotations</name>
<description>Java annotations to use in Mojos</description>
<dependencies>
<dependency>
......
......@@ -30,6 +30,10 @@ import java.lang.annotation.Target;
* Used to configure your Mojo parameters to be injected by
* <a href="/ref/current/maven-core/apidocs/org/apache/maven/plugin/MavenPluginManager.html">
* <code>MavenPluginManager.getConfiguredMojo(...)</code></a>.
* <p>
* Beans injected into Mojo parameters are prepared by <a href="https://www.eclipse.org/sisu/">Sisu</a> JSR330-based
* container: this annotation is only effective on fields of the Mojo class itself, nested bean injection
* requires Sisu or JSR330 annotations.
*
* @author Olivier Lamy
* @since 3.0
......
......@@ -32,7 +32,7 @@ About ${project.name}
* Usage
To be able to {{{../maven-plugin-tools-annotations/index.html}use Maven Plugin Tools Java 5 Annotations}},
To be able to {{{../maven-plugin-tools-annotations/index.html}use Maven Plugin Tools Java Annotations}},
some configuration has to be done in <<<pom.xml>>>: see
{{{../maven-plugin-plugin/examples/using-annotations.html#POM_configuration} Using Plugin Tools Java5 Annotations}}
example in {{{../maven-plugin-plugin} <<<maven-plugin-plugin>>>}} documentation.
......@@ -23,7 +23,7 @@
<parent>
<artifactId>maven-plugin-tools</artifactId>
<groupId>org.apache.maven.plugin-tools</groupId>
<version>3.5</version>
<version>3.6.0</version>
</parent>
<groupId>org.apache.maven.plugins</groupId>
......@@ -33,14 +33,10 @@
<name>Maven Plugin Plugin</name>
<description>
The Plugin Plugin is used to create a Maven plugin descriptor for any Mojo's found in the source tree,
to include in the JAR. It is also used to generate Xdoc files for the Mojos as well as for updating the
plugin registry, the artifact metadata and a generic help goal.
to include in the JAR. It is also used to generate Xdoc files for the Mojos as well as the artifact metadata
and a generic help goal.
</description>
<prerequisites>
<maven>2.2.1</maven>
</prerequisites>
<properties>
<doxiaVersion>1.4</doxiaVersion>
<doxia-sitetoolsVersion>1.4</doxia-sitetoolsVersion>
......@@ -48,6 +44,10 @@
</properties>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-compat</artifactId>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-tools-api</artifactId>
......@@ -116,24 +116,6 @@
<artifactId>maven-repository-metadata</artifactId>
<version>${mavenVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-project</artifactId>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-descriptor</artifactId>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-registry</artifactId>
<version>${mavenVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-artifact-manager</artifactId>
<version>${mavenVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-artifact</artifactId>
......@@ -214,7 +196,7 @@
<configuration>
<excludes combine.children="append">
<!-- This file should exactly match the output of this project -->
<exclude>src/it/help-basic/expected-help.txt</exclude>
<exclude>src/it/help-basic**/expected-help**.txt</exclude>
</excludes>
</configuration>
</plugin>
......@@ -264,6 +246,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>3.5</version>
<!-- will use previous maven-plugin-plugin release to build current maven-plugin-plugin as configured in parent -->
<executions>
<execution>
......@@ -374,6 +357,7 @@
<properties>
<maven.compiler.source>${maven.compiler.source}</maven.compiler.source>
<maven.compiler.target>${maven.compiler.target}</maven.compiler.target>
<https.protocols>${https.protocols}</https.protocols>
</properties>
</configuration>
<executions>
......@@ -389,34 +373,5 @@
</plugins>
</build>
</profile>
<profile>
<id>maven-2</id>
<activation>
<file>
<!-- This employs that the basedir expression is only recognized by Maven 3.x (see MNG-2363) -->
<missing>${basedir}</missing>
</file>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<configuration>
<!-- see https://issues.apache.org/jira/browse/MNG-5346 -->
<skipErrorNoDescriptorsFound>true</skipErrorNoDescriptorsFound>
</configuration>
<executions>
<execution>
<id>mojo-descriptor</id>
<goals>
<goal>descriptor</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
......@@ -43,11 +43,6 @@ under the License.
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-project</artifactId>
<version>@mavenVersion@</version>
</dependency>
<dependency>
......
......@@ -56,12 +56,6 @@ under the License.
<artifactId>junit</artifactId>
<version>3.8.2</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-project</artifactId>
<version>@mavenVersion@</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
......
......@@ -47,12 +47,7 @@ under the License.
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-artifact</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-project</artifactId>
<artifactId>maven-compat</artifactId>
<version>@mavenVersion@</version>
</dependency>
<dependency>
......
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
invoker.debug = false
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Licensed to the Apache Software Foundation (ASF) under one
~ or more contributor license agreements. See the NOTICE file
~ distributed with this work for additional information
~ regarding copyright ownership. The ASF licenses this file
~ to you under the Apache License, Version 2.0 (the
~ "License"); you may not use this file except in compliance
~ with the License. You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing,
~ software distributed under the License is distributed on an
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
~ KIND, either express or implied. See the License for the
~ specific language governing permissions and limitations
~ under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.maven.its.asm-failure</groupId>
<artifactId>asm-failure</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>maven-plugin</packaging>
<name>MPLUGIN-328 ignore ASM failures when reading .class</name>
<description>
ASM failure caused by com.ibm.icu:icu4j:2.6.1 dependency, precisely
com/ibm/icu/impl/data/LocaleElements_zh__PINYIN.class
Same failure happens with dependencies compiled with AspectJ
</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>
<plugin>
<artifactId>maven-plugin-plugin</artifactId>
<version>@project.version@</version>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>3.0</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>@project.version@</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.ibm.icu</groupId>
<artifactId>icu4j</artifactId>
<version>2.6.1</version>
</dependency>
</dependencies>
</project>
package org.apache.maven.plugin.coreit;
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Component;
import org.apache.maven.plugins.annotations.Mojo;
import org.apache.maven.plugins.annotations.Parameter;
/**
* Touches a test file.
*
* @since 1.2
*/
@Mojo( name = "first" )
public class FirstMojo
extends AbstractMojo
{
/**
* @since 0.1
* @deprecated As of 0.2
*/
@Parameter( alias = "alias" )
private String aliasedParam;
public void execute()
throws MojoExecutionException
{
getLog().info( "touch" );
}
}
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
build = new File( basedir, "build.log" ).text
assert build.contains( "[WARNING] Error analyzing class com/ibm/icu/impl/data/LocaleElements_zh__PINYIN.class in " )
assert build =~ /com[\\\/]ibm[\\\/]icu[\\\/]icu4j[\\\/]2.6.1[\\\/]icu4j-2.6.1.jar: ignoring class/
return true;
[INFO] help-jdk11 1.0-SNAPSHOT
Tests generation and compilation of the help mojo.
help-jdk11:test
Deprecated. As of 1.0, use the "quoted" goal instead.
MOJO-DESCRIPTION. Some 'quotation' marks and backslashes '\\', some important
javadoc
and an inline link to AnotherMojo.
Available parameters:
defaultParam (Default: escape\backslash)
This parameter uses 'quotation' marks and backslashes '\\' in its
description. Those characters must be escaped in Java string literals.
deprecatedParam
Deprecated. As of version 1.0, use the {@link #defaultParam} instead.
This parameter is deprecated.
undocumentedParam
Required: Yes
User property: test.undocumented
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
invoker.java.version = 11+
invoker.maven.version = 3.0+
invoker.goals.1 = clean install -DskipTests
invoker.goals.2 = org.apache.maven.its.plugin:help-jdk11:1.0-SNAPSHOT:help
invoker.goals.3 = --log-file help.log org.apache.maven.its.plugin:help-jdk11:1.0-SNAPSHOT:help
# --log-file option is only supported by Maven 3
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.maven.its.plugin</groupId>
<artifactId>help-jdk11</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>maven-plugin</packaging>
<description>
Tests generation and compilation of the help mojo.
</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-utils</artifactId>
<version>3.0.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>@project.version@</version>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.0</version>
<configuration>
<source>11</source>
<target>11</target>
<release>11</release>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>@project.version@</version>
<executions>
<execution>
<id>default-descriptor</id>
<phase>process-classes</phase>
</execution>
<execution>
<id>help-goal</id>
<goals>
<goal>helpmojo</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
package org.apache.maven.tools.plugin.javadoc;
package test;
/*
* Licensed to the Apache Software Foundation (ASF) under one
......@@ -19,75 +19,50 @@ package org.apache.maven.tools.plugin.javadoc;
* under the License.
*/
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugins.annotations.Mojo;
import org.apache.maven.plugins.annotations.Parameter;
/**
* Abstract <code>Taglet</code> for annotations specified at the Mojo class level.
* MOJO-DESCRIPTION. Some "quotation" marks and backslashes '\\', some <strong>important</strong> javadoc<br> and an
* inline link to {@link test.AnotherMojo}.
*
* @author <a href="mailto:vincent.siveton@gmail.com">Vincent Siveton</a>
* @version $Id: AbstractMojoTypeTaglet.java 638333 2008-03-18 11:39:14Z bentmann $
*/
public abstract class AbstractMojoTypeTaglet
extends AbstractMojoTaglet
{
/**
* @return <code>false</code> since this annotation can <b>NOT</b> be used in constructor documentation.
* @see com.sun.tools.doclets.Taglet#inConstructor()
* @deprecated As of 1.0, use the "quoted" goal instead.
* @since 2.1
*/
public final boolean inConstructor()
@Mojo( name= "test" )
public class MyMojo
extends AbstractMojo
{
return false;
}
/**
* @return <code>false</code> since this annotation can <b>NOT</b> be used in field documentation.
* @see com.sun.tools.doclets.Taglet#inField()
* This parameter uses "quotation" marks and backslashes '\\' in its description. Those characters <em>must</em> be
* escaped in Java string literals.
*
* @since 2.0
*/
public final boolean inField()
{
return false;
}
@Parameter( defaultValue = "escape\\backslash" )
private String defaultParam;
/**
* @return <code>false</code> since this annotation can <b>NOT</b> be used in method documentation.
* @see com.sun.tools.doclets.Taglet#inMethod()
* This parameter is deprecated.
*
* @deprecated As of version 1.0, use the {@link #defaultParam} instead.
*/
public final boolean inMethod()
{
return false;
}
@Parameter
private String deprecatedParam;
/**
* @return <code>false</code> since this annotation can <b>NOT</b> be used in overview documentation.
* @see com.sun.tools.doclets.Taglet#inOverview()
*/
public final boolean inOverview()
{
return false;
}
@Parameter( property = "test.undocumented", required = true )
private String undocumentedParam;
/**
* @return <code>false</code> since this annotation can <b>NOT</b> be used in package documentation.
* @see com.sun.tools.doclets.Taglet#inPackage()
* Readonly parameter: should not be proposed for configuration.
*/
public final boolean inPackage()
{
return false;
}
@Parameter( defaultValue = "not for configuration", readonly = true )
private String readonly;
/**
* @return <code>true</code> since this annotation can be used in type documentation.
* @see com.sun.tools.doclets.Taglet#inType()
*/
public final boolean inType()
public void execute()
{
return true;
}
/**
* @return <code>false</code> since this annotation can <b>NOT</b> be used in inline tag.
* @see com.sun.tools.doclets.Taglet#isInlineTag()
*/
public final boolean isInlineTag()
{
return false;
}
}
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
detail = true
goal = test
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
expected = new File( basedir, "expected-help.txt" ).text.trim().replace( "\r", "" );
log = new File( basedir, "help.log" ).text.replace( "\r", "" );
log = log.substring( log.indexOf( "[INFO] help-jdk11 1.0-SNAPSHOT" ) );
log = log.substring( 0, log.indexOf( "[INFO]", 5 ) ).trim();
assert log == expected;
return true;
\ No newline at end of file
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
invoker.java.version = 11+
invoker.goals.1 = clean install -DskipTests
invoker.goals.2 = org.apache.maven.its.basic-java-annotations:maven-it-basic-java-annotations:1.0-SNAPSHOT:it0014
invoker.goals.3 = org.apache.maven.its.basic-java-annotations:maven-it-basic-java-annotations:1.0-SNAPSHOT:help
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.maven.its.basic-java-annotations</groupId>
<artifactId>maven-it-basic-java-annotations</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>maven-plugin</packaging>
<name>Maven Integration Test :: basic-java-annotations-jdk8</name>
<description>
Test plugin-plugin, which tests maven-plugin-tools-api and
maven-plugin-tools-java. This will generate a plugin descriptor from
java-based mojo sources, install the plugin, and then use it.
</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<!-- pom properties values not taken into account since invoker defines properties -->
<!-- that override what's defined in pom -->
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
</properties>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>2.2.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-core</artifactId>
<version>2.2.1</version>
</dependency>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-utils</artifactId>
<version>3.0.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>@project.version@</version>
<scope>compile</scope>
</dependency>
</dependencies>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.0</version>
<configuration>
<source>11</source><!-- avoid ${maven.compiler.source} since value is not as expected -->
<target>11</target><!-- avoid ${maven.compiler.target} since value is not as expected -->
<release>11</release>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>@project.version@</version>
<configuration>
<skipErrorNoDescriptorsFound>true</skipErrorNoDescriptorsFound>
</configuration>
<executions>
<execution>
<id>mojo-descriptor</id>
<goals>
<goal>descriptor</goal>
</goals>
</execution>
<execution>
<id>help-goal</id>
<goals>
<goal>helpmojo</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>