I have added the lint plugin in my JAVA Project. But, it is showing up some warnings in build.gradle file when I am doing clean build.It is not showing any warning or error in the JAVA code. I want to ignore the code in build.gradle and want to focus on the main JAVA code. How can I ignore it?
gradleLint.ignore { // my build script code that makes the linter suspicious... }
I can ignore a piece of code using above , but how to ignore build.gradle?
Moreover, while generating Lint report using generateGradleLintReport, it is not generating anything.
I have the following linting rules:
gradleLint.rules = ['dependency-parentheses', 'dependency-tuple']
Which other rules to add so that lint gives the compilation errors.
Asked
Active
Viewed 617 times
1

tanmayghosh2507
- 773
- 3
- 12
- 31
-
which IDE are you using – Aniruddha K.M Mar 21 '16 at 05:53
-
Why can't you clean up your code to make the linter happy? – chrylis -cautiouslyoptimistic- Mar 21 '16 at 05:53
-
The code is in git. And I am using Jenkins to build the code. @war_Hero – tanmayghosh2507 Mar 21 '16 at 05:55
-
The linter is showing up just warnings in build.gradle code, which are important. I just can't clean it up. They have to be there in code. @chrylis – tanmayghosh2507 Mar 21 '16 at 05:57
-
What happens if you put the entire contents of your build.gradle inside `gradleLint.ignore{...}` ? – RaGe Mar 22 '16 at 12:57
-
Okay. I thought this too but not tried. Kind of inception thingy. Anyways, will try and let you know. – tanmayghosh2507 Mar 25 '16 at 05:26