Excellent stuff Stephen, thanks. We should try to get this into a release as soon as possible.
On 2011-05-21 02:21, [email protected] wrote: > Author: stephenc > Date: Sat May 21 00:21:26 2011 > New Revision: 1125604 > > URL: http://svn.apache.org/viewvc?rev=1125604&view=rev > Log: > No point sitting on this change any longer. > > Modified: > > maven/plugin-tools/trunk/maven-plugin-plugin/src/main/java/org/apache/maven/plugin/plugin/AbstractGeneratorMojo.java > > Modified: > maven/plugin-tools/trunk/maven-plugin-plugin/src/main/java/org/apache/maven/plugin/plugin/AbstractGeneratorMojo.java > URL: > http://svn.apache.org/viewvc/maven/plugin-tools/trunk/maven-plugin-plugin/src/main/java/org/apache/maven/plugin/plugin/AbstractGeneratorMojo.java?rev=1125604&r1=1125603&r2=1125604&view=diff > ============================================================================== > --- > maven/plugin-tools/trunk/maven-plugin-plugin/src/main/java/org/apache/maven/plugin/plugin/AbstractGeneratorMojo.java > (original) > +++ > maven/plugin-tools/trunk/maven-plugin-plugin/src/main/java/org/apache/maven/plugin/plugin/AbstractGeneratorMojo.java > Sat May 21 00:21:26 2011 > @@ -125,6 +125,16 @@ public abstract class AbstractGeneratorM > return; > } > > + if ( project.getArtifactId().toLowerCase().startsWith( "maven-" ) > + && project.getArtifactId().toLowerCase().endsWith( "-plugin" ) > + && !"org.apache.maven.plugin".equals( project.getGroupId() ) ) > + { > + getLog().error( "\n\nArtifact Ids of the format maven-___-plugin > are reserved for \n" > + + "plugins in the Group Id > org.apache.maven.plugins\n" > + + "Please change your artifactId to the > format ___-maven-plugin\n" > + + "In the future this error will break the > build.\n\n" ); > + } > + > String defaultGoalPrefix = > PluginDescriptor.getGoalPrefixFromArtifactId( project.getArtifactId() ); > if ( goalPrefix == null ) > { > > > -- Dennis Lundberg --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
