1

Is there any configuration to turn this warnings in errors when you're running gradlew lint check?

The example message is like this:

w: warning: viewModel.progressVisibility.getValue() is a boxed field but needs to be un-boxed to execute android:visibility.

1 Answers1

0

Based on the answer https://stackoverflow.com/a/54321834/6100078, you need to add this line on the application gradle:

android {

...

kapt {
    javacOptions {
        option("-Xmaxerrs", 1000)
        option("-Werror")
    }
}

This will make any build warning be reported as error.

Igor Escodro
  • 1,307
  • 2
  • 16
  • 30