gpt4 book ai didi

android - "The signing configuration should be specified in Gradle build scripts"...我做到了

转载 作者:塔克拉玛干 更新时间:2023-11-01 21:35:43 24 4
gpt4 key购买 nike

我在申请签名时遇到了一个大问题:我已经按照文档设置了签名配置:

signingConfigs {
release {
storeFile file("lomapnew.keystore")
storePassword "myPassword"
keyAlias "myAlias"
keyPassword "Something...."
}
}

但我仍然收到此错误消息:“应在 Gradle 构建脚本中指定签名配置”

enter image description here

最佳答案

我要大胆猜测您还没有为发布构建类型设置签名配置。调试构建类型是自动的,因此对于所有其他构建类型(包括发布)来说这是一个必要步骤并不明显。

您可以像这样应用签名配置:

android {
signingConfigs {
// It's not necessary to specify, but I like to keep the debug keystore
// in SCM so all our debug builds (on all workstations) use the same
// key for convenience
debug {
storeFile file("debug.keystore")
}
release {
storeFile file("release.keystore")
storePassword "myPassword"
keyAlias "myAlias"
keyPassword "Something...."
}
}

buildTypes {
/* This one happens automatically
debug {
signingConfig signingConfigs.debug
}
*/
release {
signingConfig signingConfigs.release
}
}
}

关于android - "The signing configuration should be specified in Gradle build scripts"...我做到了,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19231838/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com