Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 2.3
-
Fix Version/s: 2.5
-
Component/s: None
-
Labels:None
Description
Most maven report plugins will not generate a report if there are no input files. For example, a pom that defines the javadoc report plugin but has no source does not get a javadoc report.
However the pmd plugin generates empty pmd and cmd reports even for projects that have no source. In particular this means that parent poms that want to define pmd reports for the child modules get a "project reports" menu with pointless pmd/cmd pages. Given that poms lack a "pluginManagement" pom section, this is quite annoying.
Issue Links
- is duplicated by
-
MPMD-101
PMD/CPD Reports Generated for Projects Using POM Packaging
-
This problem is especially annoying if you use individual rulesets for each maven "leaf" module: for findbugs and checkstyle (and PMD) we define in the root pom the config file with ${project.artifactId}/configuration.xml. For pmd this does not work because of this bug. The pmd module always wants to read the configuration for our parent modules that do not contain source (just a modules section in the pom). So we need to create a dummy file for each of our parent modules just to prevent pmd from reporting a build failure.