cordova android (一)

来源:互联网 发布:mac os 10.13 发布 编辑:程序博客网 时间:2024/06/05 03:52

一  环境配置


cordova 6.2             支持Android 6和iOS 9             

 

cordova版本说明:
http://rensanning.iteye.com/blog/2201683

 

1 nodejs
2 ant
3 cordova 

4 android 23

 

android 23  离线安装方式(当然adt要先下好 装好)

把  android-23

放到  D:\software\adt-bundle-windows-x86-20130917.467161976\adt-bundle-windows-x86-20130917\sdk\platforms

把  23.0.3 (一定要改正这样格式的命名

D:\software\adt-bundle-windows-x86-20130917.467161976\adt-bundle-windows-x86-20130917\sdk\build-tools

 

离线下载地址:http://mirrors.neusoft.edu.cn/android/repository/

就算安装好了    

 

 

一. 安装Node.js基本环境

  官网下载地址:https://nodejs.org/

  安装成功之后可以使用简单命令查看其版本

node -v

  npm相关命令

node cli.js install npm -gf         //安装最新的NPMnode cli.js install npm@1.0.105 -gf //可以安装指定版本的NPM

  

二.  安装Git: http://git-scm.com/

 

三  可以指定淘宝镜像  npm config setregistryhttp://registry.npm.taobao.org

四  安装 cordova  :npm install -g cordova

 

安装指定版本的Cordova

npm install -g cordova@4.0.0

 

五  创建项目:

 

cordova create test8 com.yourname.myapp test8

cd test8

cordova platforms add android

cordova run android

 

加插件:

 http://www.cnblogs.com/piaoqingsong/p/5048122.html

0 0