You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by de...@apache.org on 2008/02/05 00:28:55 UTC

svn commit: r618491 - /maven/plugins/trunk/maven-checkstyle-plugin/src/site/apt/examples/custom-developed-checkstyle.apt

Author: dennisl
Date: Mon Feb  4 15:28:54 2008
New Revision: 618491

URL: http://svn.apache.org/viewvc?rev=618491&view=rev
Log:
o Fix the configuration so that it works for both 'mvn site' and 'mvn checkstyle:check'.

Modified:
    maven/plugins/trunk/maven-checkstyle-plugin/src/site/apt/examples/custom-developed-checkstyle.apt

Modified: maven/plugins/trunk/maven-checkstyle-plugin/src/site/apt/examples/custom-developed-checkstyle.apt
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-checkstyle-plugin/src/site/apt/examples/custom-developed-checkstyle.apt?rev=618491&r1=618490&r2=618491&view=diff
==============================================================================
--- maven/plugins/trunk/maven-checkstyle-plugin/src/site/apt/examples/custom-developed-checkstyle.apt (original)
+++ maven/plugins/trunk/maven-checkstyle-plugin/src/site/apt/examples/custom-developed-checkstyle.apt Mon Feb  4 15:28:54 2008
@@ -216,9 +216,12 @@
  Checkstyle checks. In the <<<pom.xml>>> of that project, add the following
  configuration.
 
- <<Note:>> You have to specify this configuration in the <<<\<build\>>>>
- element of your <<<pom.xml>>>. It will not work inside the <<<\<reporting\>>>>
- element, because <<<\<reporting\>>>> does not support plugin dependencies.
+ <<Note:>> You have to specify a plugin dependency on
+ <mycompany-checkstyle-checks> in the <<<\<build\>>>> element of your
+ <<<pom.xml>>>. It will not work inside the <<<\<reporting\>>>> element,
+ because <<<\<reporting\>>>> does not support plugin dependencies. The rest of
+ the configuration is done in the normal way in the <<<\<reporting\>>>>
+ element.
 
 +-----+
 <project>
@@ -228,10 +231,6 @@
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-checkstyle-plugin</artifactId>
-        <configuration>
-          <configLocation>checkstyle.xml</configLocation>
-          <packageNamesLocation>com/mycompany/checks/packagenames.xml</packageNamesLocation>
-        </configuration>
         <dependencies>
           <dependency>
             <groupId>com.mycompany</groupId>
@@ -242,6 +241,18 @@
       </plugin>
     </plugins>
   </build>
+  <reporting>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-checkstyle-plugin</artifactId>
+        <configuration>
+          <configLocation>checkstyle.xml</configLocation>
+          <packageNamesLocation>com/mycompany/checks/packagenames.xml</packageNamesLocation>
+        </configuration>
+      </plugin>
+    </plugins>
+  </reporting>
   ...
 </project>
 +-----+