Alex Volanis | 7004a61 | 2018-01-24 10:30:13 -0500 | [diff] [blame] | 1 | |
| 2 | // ================================================================= |
| 3 | // Configure the Gradle code quality plugins here. |
| 4 | // |
| 5 | |
D. Can Celasun | 76fa8c9 | 2019-10-18 15:15:45 +0100 | [diff] [blame] | 6 | dependencies { |
| 7 | spotbugs configurations.spotbugsPlugins.dependencies |
| 8 | spotbugsPlugins 'com.h3xstream.findsecbugs:findsecbugs-plugin:1.8.0' |
| 9 | } |
Alex Volanis | 7004a61 | 2018-01-24 10:30:13 -0500 | [diff] [blame] | 10 | |
D. Can Celasun | 76fa8c9 | 2019-10-18 15:15:45 +0100 | [diff] [blame] | 11 | apply plugin: 'com.github.spotbugs' |
| 12 | |
| 13 | spotbugs{ |
Alex Volanis | 7004a61 | 2018-01-24 10:30:13 -0500 | [diff] [blame] | 14 | ignoreFailures = true |
D. Can Celasun | 76fa8c9 | 2019-10-18 15:15:45 +0100 | [diff] [blame] | 15 | toolVersion = '3.1.12' |
Alex Volanis | 7004a61 | 2018-01-24 10:30:13 -0500 | [diff] [blame] | 16 | sourceSets = [ sourceSets.main ] |
| 17 | effort = 'max' |
| 18 | reportLevel = 'low' |
| 19 | excludeFilter = file('code_quality_tools/findbugs-filter.xml') |
| 20 | } |
| 21 | |
D. Can Celasun | 76fa8c9 | 2019-10-18 15:15:45 +0100 | [diff] [blame] | 22 | tasks.withType(SpotBugsTask) { |
Alex Volanis | 7004a61 | 2018-01-24 10:30:13 -0500 | [diff] [blame] | 23 | reports { |
| 24 | text.enabled = false |
| 25 | html.enabled = true |
| 26 | xml.enabled = false |
| 27 | } |
| 28 | } |
| 29 | |
| 30 | apply plugin: 'pmd' |
| 31 | |
| 32 | pmd { |
| 33 | ignoreFailures = true |
| 34 | toolVersion = '6.0.0' |
| 35 | sourceSets = [ sourceSets.main ] |
Alex Volanis | 7004a61 | 2018-01-24 10:30:13 -0500 | [diff] [blame] | 36 | ruleSets = [ 'java-basic' ] |
| 37 | } |
| 38 | |
| 39 | tasks.withType(Pmd) { |
| 40 | reports { |
| 41 | html.enabled = true |
| 42 | xml.enabled = false |
| 43 | } |
| 44 | } |