美文网首页
Ionic 安卓编译环境配置

Ionic 安卓编译环境配置

作者: EvolAi | 来源:发表于2017-08-04 16:41 被阅读0次

windows 64位:

下载JDK1.7,按照图解配置:

http://www.greenxf.com/soft/60331.html

下载第一个android-studio-bundle-143.2821654-windows.exe:

http://www.android-studio.org/index.php/download

打开CMD运行:

D:

cd www\cc3

创建android平台:

ionic platform add android

ionic browser add crosswalk

下载插件:

cordova plugin add https://github.com/Initsogar/cordova-webintent.git

cordova plugin addhttps://github.com/apache/cordova-plugin-camera.git

cordova plugin add https://github.com/apache/cordova-plugin-console.git

cordova plugin addhttps://github.com/apache/cordova-plugin-device.git

cordova plugin addhttps://github.com/apache/cordova-plugin-file.git

cordova plugin addhttps://github.com/apache/cordova-plugin-file-transfer.git

cordova plugin addhttps://github.com/apache/cordova-plugin-network-information.git

cordova plugin addhttps://github.com/apache/cordova-plugin-splashscreen.git

cordova plugin addhttps://github.com/apache/cordova-plugin-statusbar.git

cordova plugin addhttps://github.com/apache/cordova-plugin-whitelist.git

cordova plugin addhttps://github.com/EddyVerbruggen/Toast-PhoneGap-Plugin.git

cordova plugin addhttps://github.com/driftyco/ionic-plugins-keyboard.git

cordova plugin add jpush-phonegap-plugin@2.1.1 --variable API_KEY=83250c211a16b9a14c371af9

cordova plugin add cordova-plugin-streaming-media

cordova plugin addhttps://github.com/apache/cordova-plugin-media-capture.git

cordova plugin add cordova-plugin-wechat --variable wechatappid=wxa5e56d2079541133

编译android:

ionic build android

测试APK地址:

platforms\android\build\outputs\apk\android-armv7-debug.apk

编译发行版:

cc3/config.xml和www/js/services/Cfg.js内版本号加1,cc3/config.xml内的CFBundleShortVersionString下面数字加1

复制release-signing.properties到android项目目录下,hfq.sign放在cc3/sign/目录

release-signing.properties:http://192.168.0.102:8080/tsoa/frame/document.jsp?unid=22D8653574AA4D5DA982294986509717

hfq.sign:http://192.168.0.102:8080/tsoa/frame/document.jsp?unid=283AB71B3E104D698F35DF5C26D49830

IOS编译前运行:

cp plugins/cn.jpush.phonegap.JPushPlugin/src/ios/PushConfig.plist platforms/ios/艺人邦/Resources/PushConfig.plist

编译:

ionic build ios --release

ionic build android --release

自动安装:

ionic run android --livereload -c -s

相关文章

网友评论

      本文标题: Ionic 安卓编译环境配置

      本文链接:https://www.haomeiwen.com/subject/ucqblxtx.html