如何生成签名文件不赘述。
build.gradle 加入如下语句即可:android {
compileSdkVersion 10
buildToolsVersion "17.0.0"
signingConfigs {
debug{
storeFile = file("D:\\eclipse workspace\\dbball-cn\\dbball-cn\\release.keystore")
keyAlias = "sunose"
storePassword = "sunose"
keyPassword = "sunose"
}
release{
storeFile = file("D:\\eclipse workspace\\dbball-cn\\dbball-cn\\release.keystore")
keyAlias = "sunose"
storePassword = "sunose"
keyPassword = "sunose"
}
}
注意如何发布运行测试的时候出现:INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES
错误,是由于以前的版本已经安装使用了不同签名,只要删除掉该app
从新发布即可。