[JAVA] FindBugs in Gradle doesn't output results in HTML

Summary

To run FindBugs in Gradle, just write findbugs {} in your subproject. However, as it is, the result is output only in XML, not in HTML.

I will introduce how to output in HTML.

Method

(For Android) Describe the following in the subproject build.gradle.

build.gradle


tasks.withType(FindBugs) {
    reports {
        xml.enabled = false //You can stop the XML output by writing this
        html.enabled = true
    }
} 

This will output the FindBugs results in HTML.

reference

https://stackoverflow.com/questions/15406469/how-to-generate-html-output-using-gradle-findbugs-plugin

Recommended Posts

FindBugs in Gradle doesn't output results in HTML
Output triangle in Ruby
Output in multiples of 3
Output relative path in .classpath file generated by gradle eclipse