PMD Plugin for Eclipse

PMD Plugin Installation process for Eclipse

PMD is not only embedded with maven, we can install for eclipse also as plugin where we can go and check code againest the rule. If you have previously installed a version of the PMD Eclipse plugin prior to November 2012, then you should remove/uninstall it first.

To install the PMD for Eclipse plugin:

1. In Eclipse, click on Help -> Install New Software...

2. Click on Add..

3. Enter the following:

PMD eclipse plugin installation

and click OK.

4. You should see PMD for Eclipse with different version like 2,3 and 4. Select the checkbox next to Eclipse 3 (Eclipse version: 3.5.2) and click Next >.

PMD eclipse plugin

5. You'll need to accept the license and confirm you want to install a plugin that is not digitally signed. Go ahead and install it anyway.

6. Restart eclipse. Then you can find PMD in the preference tab. Using this you can customize the ruleset which you want to test your code againest the rule

PMD Rule tab in eclipse