You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by br...@apache.org on 2011/02/07 00:17:40 UTC

svn commit: r1067803 - in /maven/site/trunk/src/site/apt/guides: introduction/introduction-to-plugin-prefix-mapping.apt plugin/guide-java-plugin-development.apt

Author: brett
Date: Sun Feb  6 23:17:40 2011
New Revision: 1067803

URL: http://svn.apache.org/viewvc?rev=1067803&view=rev
Log:
[MNGSITE-128] clarify plugin / artifact ID / prefix mapping 

Modified:
    maven/site/trunk/src/site/apt/guides/introduction/introduction-to-plugin-prefix-mapping.apt
    maven/site/trunk/src/site/apt/guides/plugin/guide-java-plugin-development.apt

Modified: maven/site/trunk/src/site/apt/guides/introduction/introduction-to-plugin-prefix-mapping.apt
URL: http://svn.apache.org/viewvc/maven/site/trunk/src/site/apt/guides/introduction/introduction-to-plugin-prefix-mapping.apt?rev=1067803&r1=1067802&r2=1067803&view=diff
==============================================================================
--- maven/site/trunk/src/site/apt/guides/introduction/introduction-to-plugin-prefix-mapping.apt (original)
+++ maven/site/trunk/src/site/apt/guides/introduction/introduction-to-plugin-prefix-mapping.apt Sun Feb  6 23:17:40 2011
@@ -51,12 +51,13 @@ Introduction to Plugin Prefix Resolution
 
   In order to give users a convenient prefix with which to reference your plugin
   a prefix must be associated with your plugin when it is built. By default, Maven
-  will make a guess at the plugin-prefix to be used, by assuming the plugin's artifactId
-  fits the pattern:
+  will make a guess at the plugin-prefix to be used, by removing any instances of
+  "maven" or "plugin" surrounded by dashes in the plugin's artifact ID. The
+  conventional artifact ID formats to use are:
 
-+---+
-maven-${prefix}-plugin
-+---+
+    * <<<maven-${prefix}-plugin>>> - for plugins from the Apache Maven project
+
+    * <<<${prefix}-maven-plugin>>> - for plugins from other sources
 
   If your plugin's artifactId fits this pattern, Maven will automatically map
   your plugin to the correct prefix in the metadata stored within your plugin's

Modified: maven/site/trunk/src/site/apt/guides/plugin/guide-java-plugin-development.apt
URL: http://svn.apache.org/viewvc/maven/site/trunk/src/site/apt/guides/plugin/guide-java-plugin-development.apt?rev=1067803&r1=1067802&r2=1067803&view=diff
==============================================================================
--- maven/site/trunk/src/site/apt/guides/plugin/guide-java-plugin-development.apt (original)
+++ maven/site/trunk/src/site/apt/guides/plugin/guide-java-plugin-development.apt Sun Feb  6 23:17:40 2011
@@ -206,13 +206,12 @@ mvn groupID:artifactID:version:goal
   repository, you can omit its version number. So just use
   "<<<mvn sample.plugin:maven-hello-plugin:sayhi>>>" to run your plugin.
 
-  * The "<<<maven-$name-plugin>>>" and "<<<$name-maven-plugin>>>" artifactId
-  patterns are treated in a special way. If no plugin matches the artifactId
-  specified on the command line, Maven will try expanding the artifactId to these
-  patterns in that order. So in the case of our example, you can use
-  "<<<mvn sample.plugin:hello:sayhi>>>" to run your plugin.  Note: these 2
-  patterns are used respectively by the official Maven 2 plugins and the Mojo
-  project plugins.
+  * You can assign a shortened prefix to your plugin, such as <<<mvn hello:sayhi>>>.
+    This is done automatically if you follow the convention of using
+    <<<${prefix}-maven-plugin>>> (or <<<maven-${prefix}-plugin>>> if the plugin is
+    part of the Apache Maven project). You may also assign one through additional
+    configuration - for more information see
+    {{{../introduction/introduction-to-plugin-prefix-mapping.html} Introduction to Plugin Prefix Mapping}}.
 
   * Finally, you can also add your plugin's groupId to the list of groupIds
   searched by default.  To do this, you need to add the following to