android - 如何使用 Android aaptOptions?

标签 android android-gradle-plugin aapt

aaptOptions.noCompress等是什么意思;谁能给我解释一下?

android {
    aaptOptions {
        noCompress 'foo', 'bar'
        ignoreAssetsPattern '!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~'
    }
}

这会影响所有使用 aapt 的任务。

最佳答案

ignoreAssetsPattern 仅记录在 sources 中:

 * Patterns syntax:
 * - Delimiter is :
 * - Entry can start with the flag ! to avoid printing a warning
 *   about the file being ignored.
 * - Entry can have the flag "<dir>" to match only directories
 *   or <file> to match only files. Default is to match both.
 * - Entry can be a simplified glob "<prefix>*" or "*<suffix>"
 *   where prefix/suffix must have at least 1 character (so that
 *   we don't match a '*' catch-all pattern.)
 * - The special filenames "." and ".." are always ignored.
 * - Otherwise the full string is matched.
 * - match is not case-sensitive.

关于android - 如何使用 Android aaptOptions?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28934333/

相关文章:

android - Sherlock ActionBar 溢出菜单 TextColor

android - Gradle 构建变体的依赖性

javascript - Android 键盘更换网页 View

android - 获取android默认浏览器的url

java - Android YouTube API - 无缓冲处理方向变化

android - 如何在 Gradle 中的 buildType 中设置版本名称

android-studio - 由于gradle守护程序是什么gradle版本?

android - 字符串中未转义的撇号

android - Google API 为 Android 抛出 no-crunch 错误

android - AAPT:错误: '#ffffff'与属性drawable(attr)引用不兼容