我正在使用 Cordova 5.4.1。 我想为 android 创建一个签名的 APK。
我遵循了这个: https://blog.nraboy.com/2014/09/signing-apache-cordova-android-app-release/
^^^^ 但这不起作用,它忽略了我的 ant.properties 文件。
ant.properties
key.store=example.keystore
key.alias=example
所以我改用这个: http://shallowsky.com/blog/programming/cordova-create-signed-app.html
成功了!但是我使用了一个名为 release-signing.properties 的文件(而不是 ant.properties)
release-signing.properties
storeFile=example.keystore
storeType=jks
keyAlias=example
顺便说一句,要启动构建,我输入命令:
cordova build android --release
所以我猜 release-signing.properties 是 Cordova 5+ 的方式?
(我只是不确定我是否应该使用 ant。我猜不是因为它不起作用:/)
最佳答案
是的。这是 5.4.1 中较新的处理方式。它仍然是 6.0.+ 的一个选项。 Cordova Docs for Signing an App
如果您已经更新到 6.0.+ cordova,或者任何其他看到此信息的人,我们发现使用 build.json
文件选项最简单:Cordova Docs for using build.json
关于android - ant.properties 与 release-signing.properties,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34428939/