Gradle Plugin Samples 之 Gradle Build Configs(五)
2015-07-20 15:03
351 查看
http://ask.android-studio.org/?/article/29
在 app/build.gradle 中,有以下内容:
signingConfigs 元素用于设置签名文件信息。在本例中,我们使用了 app/keystore 文件为 release 分支进行签名。默认使用
SDK 中的 debug.keystore 为 debug 分支进行签名。
我们可以在 buildTypes 中对
APK 的一些信息可以设置,例如本例中将 debug 分支下
APK 包名在默认的包名后追加 .debug ,从而最终包名为 cc.bb.aa.gradle_build_configs.debug:
Gradle Build Configs
在 app/build.gradle 中,有以下内容:android { signingConfigs { release { storeFile file('keystore') storePassword 'helloworld' keyAlias 'Android Release Key' keyPassword 'helloworld' } } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' signingConfig signingConfigs.release } debug { applicationIdSuffix ".debug" } } }
signingConfigs 元素用于设置签名文件信息。在本例中,我们使用了 app/keystore 文件为 release 分支进行签名。默认使用
SDK 中的 debug.keystore 为 debug 分支进行签名。
我们可以在 buildTypes 中对
APK 的一些信息可以设置,例如本例中将 debug 分支下
APK 包名在默认的包名后追加 .debug ,从而最终包名为 cc.bb.aa.gradle_build_configs.debug:
debug { applicationIdSuffix ".debug" }
相关文章推荐
- break、return与continue的区别.
- 如何解决"the currently displayed page contains invalid values"
- 关于一些UI的property应该使用retain、strong还是weak的问题
- Paypal SDK PayPal SDK: Request has failed with error: PAYMENT_CREATION_ERROR (422)
- TelerikUI_RadGrid_Filter 自定义方法
- BFS Codeforces Beta Round #94 (Div. 2 Only) C. Statues
- 将uiimageview设置成纯圆形
- priority_queue用法
- 动态生成juery-easyui下的折叠面板,在谷歌下格式不正确问题
- UINavigationController与UITabbarController的样式
- POJ 2785 4 Values whose Sum is 0
- iOS中手写UITableViewCell的实现与逻辑(cell固定高度展现)
- Mac OS Create case-sensitive build environment
- ant的安装、使用,build.xml简单编写
- javaGUI猜生日游戏
- Qt数据库:(四)利用QSqlQuery类执行SQL语句(二)
- 从系统UITabbar到自定义UITabbar
- 1051. Pop Sequence (25)
- 1051. Pop Sequence (25)
- JS加载文件规范,AMD,commonJS,requireJs