科尔多瓦5.0生成APK签署 [英] cordova 5.0 generate signed apk

查看:140
本文介绍了科尔多瓦5.0生成APK签署的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我用科尔多瓦5.0.0开发Android应用程序,我想运行的真机上的应用程序。

I use Cordova 5.0.0 to develop android app and I would like to run the app on real machine.

我试过两种方法生成APK签约,但没有,
一种是使用命令行签署由科尔多瓦生成APK。通过这种方式,就会造成解析错误安装APK时;
我尝试第二种方法是使用机器人工作室生成APK签署。我的步骤是进口非Android Studio项目,然后生成APK签署。通过这种方式,我安装成功,但应用程序不能打开,弹出错误信息不幸的是,XX已经停止了。

I tried two ways to generate signed apk but failed, One is used command line to sign an apk that generated by cordova. by this way, it will cause "parsing error" when install the apk; The second way I tried is using android studio to generate signed apk. My step is "import non-android studio project" then generate signed apk. By this way, I install successfully but the app can't be open and popup error info "unfortunately, xx has stopped".

有与code没有问题的。

There is no problem with the code.

任何人都可以给我一些建议吗?谢谢你。

Anyone can give me some suggestion? Thanks.

推荐答案

科尔多瓦5使用gradle这个现在来编译,所以老ant.properties不再起作用。您可以通过在平台/ Android的一个release-signing.properties文件并添加以下工作同样的伎俩:

Cordova 5 uses gradle to compile now, so the old ant.properties no longer works. You can work the same trick by creating a release-signing.properties file in platforms/android and adding the following:

storeFile=<path to="" .keystore="" file="">
storeType=jks
keyAlias=<your key="" alias="">
// optional :
keyPassword=<your-key-password>
storePassword=<your-store-password>

这篇关于科尔多瓦5.0生成APK签署的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆