News and Notes from the Makers of Nexus | Sonatype Blog

Corrected the Ant Mojo Examples

Written by Tim OBrien | July 07, 2008

De Smet Ringo wrote us to let us know of a problem with the Ant Mojo example in Chapter X. He points us to an announcement by Vincent Siveton that the groupId for plugin-tools has changed. We've fixed the Ant example and the Writing Alt Plugins chapter in response.

Here's his message to us:

The plugin dependency should read:
        <dependencies>
          <dependency>
            <groupId>org.apache.maven.plugin-tools</groupId>
            <artifactId>maven-plugin-tools-ant</artifactId>
            <version>2.4</version>
          </dependency>
        </dependencies>
for version 2.4 of the plugins and onwards...

If you stick to the 2.0.5 version of the plugin, this
is the error you get when you do site generation of your
maven plugin using Maven 2.0.9:

[INFO] --------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] --------------------------------------------------------
[INFO] Error during page generation

Embedded error: No method on class
org.apache.maven.plugin.plugin.PluginReport
[INFO] --------------------------------------------------------

You have to upgrade to the 2.4 release at least to
resolve this. <b>I just lost some time on this one,
and updated documentation will hopefully prevent this
for other users...</b>

Sorry for the trouble, you've earned a free copy of the printed book, and hopefully this correction will save some time for other readers.