Guys, I wanted generate the pmd report while building the project so I have added plugin to build section of my pom.xml but still it don't execute until I explicitly call mvn clean install pmd:pmd. I want to execute it with mvn clean install itself. is it possible ? my pom entries are as under:
<build>
<plugins>
<plugin>
<artifactId>maven-pmd-plugin</artifactId>
<version>2.4</version>
<configuration>
<skip>false</skip>
<targetJdk>${compile.source}</targetJdk>
<rulesets>
<ruleset>./current.pmd.rules.xml</ruleset>
</rulesets>
<excludes>
<exclude>com/cm/**/*.java</exclude>
<exclude>com/sm/**/*.java</exclude>
</excludes>
<linkXref>true</linkXref>
<failOnViolation>true</failOnViolation>
<executions>
<execution>
<goals>
<goal>check</goal>
<goal>cpd-check</goal>
</goals>
</execution>
</executions>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jxr-plugin</artifactId>
</plugin>
<plugin>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>2.0.1</version>
</plugin>
</plugins>
</build>
Thanks in advance.