我只是不太明白为什么这会发生在我身上,我按照https://flutter.dev/docs/deployment/android中的所有步骤上传了我的第一个版本,其中有一些错误,所以我创建了另一个(以前的备份项目)flutter项目并将其修改为现有的项目,我更改了com.flutterappstareawayvrsn1,它最初是其他的。
我已经把钥匙放好了,它仍然显示错误:
您的Android应用程序包使用了错误的密钥进行签名。请确保使用正确的签名密钥对您的应用程序包进行签名,然后重试
你怎么修好这东西?
按照https://flutter.dev/docs/deployment/android中的说明
最初的代码是:
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now,
// so `flutter run --release` works.
signingConfig signingConfigs.debug
}
}
修改后的代码是:
使用签名配置信息:
content_copy
signingConfigs {
release {
keyAlias keystoreProperties['keyAlias']
keyPassword keystoreProperties['keyPassword']
storeFile keystoreProperties['storeFile'] ?
file(keystoreProperties['storeFile']) : null
storePassword keystoreProperties['storePassword']
}
}
buildTypes {
release {
signingConfig signingConfigs.release
}
}
But I didnt modify buildtypes
{
..
.}
I took it for granted and kept it in debug rather than release