How to generate HTML output using Gradle FindBugs Plugin

Using the Gradle FindBugs plugin , how can I generate HTML output

FindBugsExtension have a specific configuration.

findbugs { toolVersion = "2.0.1" sourceSets = [sourceSets.main] ignoreFailures = true reportsDir = file("$project.buildDir/findbugsReports") effort = "max" reportLevel = "high" visitors = ["FindSqlInjection", "SwitchFallthrough"] omitVisitors = ["FindNonShortCircuit"] includeFilter = file("$rootProject.projectDir/config/findbugs/includeFilter.xml") excludeFilter = file("$rootProject.projectDir/config/findbugs/excludeFilter.xml") } 

But there is no output Properties that need to be set as anttask findbugs.

+46
html gradle findbugs
Mar 14 '13 at 10:17
source share
1 answer

Reports can only be configured in FindBugs tasks. For example:

 tasks.withType(FindBugs) { reports { xml.enabled = false html.enabled = true } } 

The same applies to other code quality plugins (Checkstyle, PMD, etc.).

+83
Mar 14 '13 at 11:44
source share



All Articles