问题:
I would like to have my Gradle build to create a release signed apk file using Gradle.我想让我的 Gradle 构建使用 Gradle 创建一个发布签名的 apk 文件。
I'm not sure if the code is correct or if I'm missing a parameter when doing gradle build
?我不确定代码是否正确,或者在执行gradle build
时是否缺少参数?
This is some of the code in my gradle file:这是我的 gradle 文件中的一些代码:
android {
...
signingConfigs {
release {
storeFile file("release.keystore")
storePassword "******"
keyAlias "******"
keyPassword "******"
}
}
}
The gradle build finishes SUCCESSFUL, and in my build/apk
folder I only see the ...-release-unsigned.apk
and ...-debug-unaligned.apk
files. gradle 构建成功完成,在我的build/apk
文件夹中,我只看到...-release-unsigned.apk
和...-debug-unaligned.apk
文件。
Any suggestions on how to solve this?有关如何解决此问题的任何建议?
解决方案:
参考一: https://en.stackoom.com/question/1Eu8g参考二: https://stackoom.com/question/1Eu8g