Skip to content

name.remal.findbugs-settings

This plugin works only if java and findbugs plugins are applied.

 

This plugin helps to configure FindBugs.

  • It update FindBugs version to the latest one.
  • It forces FindBugs dependencies to have the same version as FindBugs itself.
  • It creates a draft of FindBugs exclusions file in $rootDir/gradle/findbugs/exclude.xml. This file will will be used as default value of FindBugs.excludeFilter.
  • It excludes Kotlin classes and sources from the analysis.
  • It excludes all relocated classes from the analysis.
  • It enables XML report, customize HTML report and print all violations to console.

Also the plugin creates findbugs.excludes extension of type ExcludesExtension to setup default exclusions. The same extension is created for every FindBugs task to extend exclusions.

 

name.remal.gradle_plugins.plugins.code_quality.ExcludesExtension

Property Type Description
classNames MutableSet<String> ANT like exclude patterns of class names.
sources MutableSet<String> ANT like exclude patterns of source files.
messages MutableSet<String> Violation messages to exclude.
Method Description
void className(String value) Add ANT like exclude pattern of class names.
void classNames(String... values) Add ANT like exclude patterns of class names.
void classNames(Iterable<String> values) Add ANT like exclude patterns of class names.
void source(String value) Add ANT like exclude pattern of source files.
void sources(String... values) Add ANT like exclude patterns of source files.
void sources(Iterable<String> values) Add ANT like exclude patterns of source files.
void message(String value) Add violation message to exclude.
void messages(String... values) Add violation messages to exclude.
void messages(Iterable<String> values) Add violation messages to exclude.
void kotlin() Exclude Kotlin sources.
void groovy() Exclude Groovy sources.