gradle-lint-plugin icon indicating copy to clipboard operation
gradle-lint-plugin copied to clipboard

Improvement: fixGradleLint does not clean up empty dependency closure

Open tkruse opened this issue 6 years ago • 1 comments

Using gradle 4.3, configuration:

plugins {
    id 'nebula.lint' version '8.3.1'
    id 'nebula.info' version '3.6.0'
}
gradleLint {
    rules  = ['dependency-parentheses', 'all-dependency']
    criticalRules = ['unused-dependency']
}

gradle fixGradleLint made this change:

     playTest("org.mockito:mockito-core:$versions.mockito") {
-        exclude group: 'org.hamcrest'
     }

But could have removed curlies and parentheses as well.

tkruse avatar Nov 10 '17 08:11 tkruse

We have a com.netflix.nebula.lint.postprocess.EmptyClosureRule, but IIRC we saw some side-effects internally and turned it off. When we revisit it, we'll update this issue.

DanielThomas avatar Feb 12 '18 18:02 DanielThomas