Quality plugin configuration. Available as 'quality' closure.
| Type | Name and description |
|---|---|
java.lang.String |
animalsnifferVersionSets AnimalSniffer version. |
boolean |
autoRegistrationAutomatically register quality plugins, based on configured (affected) sources (sourceSets). |
boolean |
checkstyleEnable Checkstyle plugin. |
java.lang.String |
checkstyleVersion |
boolean |
codenarcEnable CodeNarc plugin. |
java.lang.String |
codenarcVersion |
java.lang.String |
configDirConfiguration files directory. |
boolean |
consoleReportingWhen false, disables reporting quality issues to console. |
boolean |
enabledWhen false, disables quality tasks execution. |
boolean |
findbugsEnable FindBugs plugin. |
java.lang.String |
findbugsEffortThe analysis effort level. |
java.lang.String |
findbugsLevelThe priority threshold for reporting bugs. |
java.lang.String |
findbugsVersion |
java.util.List<java.lang.String> |
lintOptionsJavac lint options to show compiler warnings, not visible by default. |
boolean |
pmdEnable PMD plugin. |
java.lang.String |
pmdVersion |
java.util.Collection<org.gradle.api.tasks.SourceSet> |
sourceSetsSource sets to apply checks on. |
boolean |
strictStrict quality leads to build fail on any violation found. |
| Constructor and description |
|---|
QualityExtension
(org.gradle.api.Project project) |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#wait(), java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Sets AnimalSniffer version. Works only when 'ru.vyarus.animalsniffer' plugin applied.
Automatically register quality plugins, based on configured (affected) sources (sourceSets). For example, if configured sources contain only java sources then only pmd, checkstyle and findbugs plugins will be activated; if only groovy sources - then codenarc only.
When disabled, quality plugins must be registered manually. Only registered plugins will be configured if configuration is not disabled with plugin flags (pmd, checkstyle etc.). True by default.
Enable Checkstyle plugin. True by default. If plugin enabled manually then disabling this option will prevent applying plugin configuration.
Enable CodeNarc plugin. Ignored if groovy plugin is not applied). True by default. If plugin enabled manually then disabling this option will prevent applying plugin configuration.
Configuration files directory. It may contain custom plugin configurations (not required). By default its gradle/config/.
When false, disables reporting quality issues to console. Only gradle general error messages will remain in logs. This may be useful in cases when project contains too many warnings. Also, console reporting require xml reports parsing, which could be time consuming in case of too many errors (large xml reports). True by default.
When false, disables quality tasks execution. Allows disabling tasks without removing plugins. Quality tasks are still registered, but skip execution, except when task called directly or through checkQualityMain (or other source set) grouping task. True by default.
Enable FindBugs plugin. True by default. If plugin enabled manually then disabling this option will prevent applying plugin configuration.
The analysis effort level. The value specified should be one of min, default, or max. Higher levels increase precision and find more bugs at the expense of running time and memory consumption. Default is 'max'.
The priority threshold for reporting bugs. If set to low, all bugs are reported. If set to medium, medium and high priority bugs are reported. If set to high, only high priority bugs are reported. Default is 'medium'.
Javac lint options to show compiler warnings, not visible by default. By default enables deprecation and unchecked options. Applies to all JavaCompile tasks. Full list of options: http://docs.oracle.com/javase/8/docs/technotes/tools/windows/javac.html#BHCJCABJ
Enable PMD plugin. True by default. If plugin enabled manually then disabling this option will prevent applying plugin configuration.
Source sets to apply checks on. Default is [project.sourceSets.main] to apply only for project sources, excluding tests.
Strict quality leads to build fail on any violation found. If disabled, all violation are just printed to console (if console reporting enabled). True by default.
Groovy Documentation