Android lint 启用检查 gradle
Android lint enable checks with gradle
我想执行 11 个禁用检查中的一些。 Android Lint documentation刚才说了这个
Some checks are disabled by default. These can be enabled by adding
the --enable flag.
如何为我的 gradle 版本激活它们?我在 build.gradle
或 lint.xml
文件中找不到任何选项。
As of version 0.7.0, you can run lint for a specific variant, or for
all variants, in which case it produces a report which describes which
specific variants a given issue applies to.
You can configure lint by adding a lintOptions section like following.
You typically only specify a few of these; this section shows all the
available options.
android {
lintOptions {
...
enable 'RtlHardcoded','RtlCompat', 'RtlEnabled'
...
}
我想执行 11 个禁用检查中的一些。 Android Lint documentation刚才说了这个
Some checks are disabled by default. These can be enabled by adding the --enable flag.
如何为我的 gradle 版本激活它们?我在 build.gradle
或 lint.xml
文件中找不到任何选项。
As of version 0.7.0, you can run lint for a specific variant, or for all variants, in which case it produces a report which describes which specific variants a given issue applies to.
You can configure lint by adding a lintOptions section like following. You typically only specify a few of these; this section shows all the available options.
android { lintOptions { ... enable 'RtlHardcoded','RtlCompat', 'RtlEnabled' ... }