I want to use a custom rule in PMD. I installed the PMD-plugin in jenkins, I also created a jar with :
- A ruleset file
- The java code for the custom rule (the custom rule extends from AbstractJavaRule).
I added this jar in the lib directory of the PMD plugin (jenkins/plugins/pmd/WEB-INF/lib).
I also added this in the pom.xml of a project (to test PMD):
<reporting>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-pmd-plugin</artifactId>
<version>2.7.1</version>
<configuration>
<linkXRef>false</linkXRef>
<targetJdk>1.6</targetJdk>
<rulesets>
<ruleset>/rulesets/basic.xml</ruleset>
</rulesets>
</configuration>
</plugin>
</plugins>
</reporting>
How can I tell to the jenkins PMD-plugin to use my new JAVA rule ?