如果我使用的是 Eclipse,我已经找到了解决这个问题的方法。
但是,我在 Android Studio(1.0 版)中找不到这个。当我构建我的项目时,我目前从 appcompat_v7 库中收到多个错误以及更多警告。我只想让 Lint 跳过测试所有库。
最佳答案
经过一段时间的查找,我在http://developer.android.com/tools/debugging/improving-w-lint.html#studio_config上的官方lint文档中找到了答案。
Module and file-specific preferences
- Run the lint tool on your module by right-clicking on your module folder or file in the Project View and selecting Analyze > Inspect Code. This displays the lint inspection results with a list of issues that lint detected in your module.
- From the Lint Warnings view, use the toolbar options to configure lint preferences for individual modules and files, and set the issue display options.
关于Android Lint 只想检查我的项目,而不是 Android Studio 中的库项目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27084152/