1. I have installed ApexPmd plugin for Eclipse(Luna).

  2. After installation I can able to "Run ApexPMD" for individual Class.

  3. (a) There is an option “Add ApexPMD Nature” providing by the ApexPMD, where it will run automatically while saving the class. (b) But, this option (Add ApexPMD Nature) is not working for me. I can able to see the violation list when I run ApexPMD for specific class. Not able to do while saving.

Any more configuration to be done to work this(Add ApexPMD Nature) feature. In ApexPmd plugin.

This is the place where i have enabled PMD.

enter image description here

  • Let us continue this discussion in chat. Feb 27, 2017 at 11:22
  • 1
    There are two PMD out there. The closed-source PMD by VillageChief that you have to pay for. It's called ApexPMD and this seems to be what you have installed. But then there is also the original, free and open-source PMD pmd.github.io. I recommend uninstalling ApexPMD and closing this question. Create a new one just describing your issues getting PMD and its Eclipse plugin to work. Oct 18, 2017 at 21:48

1 Answer 1


Did you check the checkbox to enable PMD from project properties? right click on project>> Properties >> Click on PMD(or whatever name you have given while installing the PMD plugIn) >> at top left corner you will see the checkbox Enable PMD!

You can find the latest version of PMD here:-

Details about How add new PMD rule:-

PMD Git Repository:-

Blog by Jitendra Zaa this will surly help you to get idea of PMD:-

enter image description here

  • @B SFDC I have updated my answer, this will surly help you to get idea about PMD and how to add custom rule in existing PMD ruleset for Apex. Feb 27, 2017 at 12:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.