Repository navigation
How to disable HTML report generation in spotbugs-maven-plugin configuration? #1055
|
I'm using the spotbugs-maven-plugin, and only want it to generate the spotbugsXml.xml native results file, but don't want it to generate the human readable HTML report at: target/site/spotbugs.html. After it completes: [INFO] Done SpotBugs Analysis.... I don't want it to do this: [INFO] Rendering content with org.apache.maven.skins:maven-fluido-skin:jar:2.1.0 skin Is there a way to add the spotbugs-maven-plugin to the section of the POM and disable the generation of all the human readable reports? Or is there some other easy way to tell it not to generate the human readable HTML reports? The app I'm running this on is huge and it's taking forever to generate this report, which I don't even use. |
Replies: 3 comments 4 replies
|
@hazendaz - I saw your direct email to me. Just to be clear, I'm invoking the spotbugs plugin via a profile configured in my pom. It's not part of the standard reports configured/generated in the reporting section. I looked at PMDs docs: https://maven.apache.org/plugins/maven-pmd-plugin/index.html, and they offer the following option: "pmd:pmd creates a PMD site report based on the rulesets and configuration set in the plugin". It can also generate a pmd output file aside from the site report in any of the following formats: xml, csv or txt." However, in my case I want to generate the PMD output file, and the SpotBugs output file, but NOT the site report for either tool. When I try to configure the For SpotBugs, I'd love to see the ability to suppress the site (HTML) report in both ways of invoking spotbugs. 1) via: spotbugs:spotbugs invocation at the command line, which should honor the configuration of the plugin where the plugin is declare in the FYI: This same issue was reported for the PMD maven plugin a month ago: apache/maven-pmd-plugin#189 |
|
@davewichers There was a bug when doxia 2 migration occurred here that was causing generation of the site pages even when 'site' not called. That was a result of execute() being made final by maven that was overridden in this plugin to skip the site pages and just generate the xdoc. So all runs were suddenly getting the site pages. I didn't notice that until the last few days. I've now submitted a fix to master that corrects that by querying maven session to figure out if its running site or spotbugs direct call or default allowed phase. So now those will not show up. Can you confirm if you were running everything but 'site'? If so, this will be fixed in the next release in a few days. |
|
@hazendaz - I'm now seeing this when I run Spotbugs via the command line using: So, it appears that this has been fixed so it does not generate the HTML reports by default. However, is a flag still needed so you can specify that you don't want HTML in your pom? Or is that not necessary anymore? |
@davewichers There was a bug when doxia 2 migration occurred here that was causing generation of the site pages even when 'site' not called. That was a result of execute() being made final by maven that was overridden in this plugin to skip the site pages and just generate the xdoc. So all runs were suddenly getting the site pages. I didn't notice that until the last few days. I've now submitted a fix to master that corrects that by querying maven session to figure out if its running site or spotbugs direct call or default allowed phase. So now those will not show up. Can you confirm if you were running everything but 'site'? If so, this will be fixed in the next release in a few days.