Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Lint error fixing

I am getting lint error in android studio as

Error:Execution failed for task ':app:lint'. Lint found errors in the project; aborting build. Fix the issues identified by lint, or add the following to your build script to proceed with errors:

android { lintOptions { abortOnError false } }

Information:BUILD FAILED Information:Total time: 7.288 secs Information:1 >error Information:0 warnings

Build is getting failed But it is not showing where exactly the error and even IDE(Android studio) is also not displaying any error mark in files. How to redirect lint error to source file.?

I don't want to skip the lint check.

Please help me.

like image 985
Madhukar Hebbar Avatar asked Oct 01 '15 15:10

Madhukar Hebbar


2 Answers

From the command line, run gradlew lintDebug (or gradlew lint[variantName] for a different variant).

This will generate a full lint report at /app/build/outputs. I recommend the HTML version (lint-results-debug.html). In there you will find all Android lint issues and their severity.

Alternatively, you can go to Analyze > Inspect Code in Android Studio to run lint. Switch the view to group them by severity- the errors are the ones blocking your build.

like image 58
Bryan Herbst Avatar answered Sep 28 '22 14:09

Bryan Herbst


The erros reports with the lines and exactly erros font are found in: Your app release builds folder, then:appname/app/build/reports.

there you will find the lint-results-release-fatal. Open it in any browser to find the problems.

Hope it helps.

like image 28
Thiago Silva Avatar answered Sep 28 '22 16:09

Thiago Silva