Allow for xml and html findbugs reports


(Jean-Baptiste Nizet) #1

The “official” findbugs plugin allows for generating an xml or an html report, but not both. This is annoying, since xml reports are typically used (for example) to feed sonar during a CI build, but html reports are nice when you want to check code during development. It seems like the HTML reports are generated by applying an XSL stylesheet to the XML report anyway, so it should be relatively easy to provide both reports:

  • if only xml is asked, generate the xml report to a temp directory and copy it to the reports/findbugs directory

  • if only html is asked, generate the xml report to a temp directory, and apply the xslt stylesheet with the reports/findbugs directory as output dir

  • if both are asked, do all of the above


(Peter Niederwieser) #2

Our immediate goal is to support all major configuration options of the FindBugs Ant task (we have some work to do there); what you are asking for may be added at a later point. Meanwhile, you can configure the Sonar build to generate XML reports, and the other builds to generate HTML reports.