[phonegap]安装phonegap

下载nodejs,安装,单nodejs4.0.0 x64编译时,还需要python2.6 or python2.7;

参考怎么安装python2.7:            http://jingyan.baidu.com/article/19192ad8399a62e53e5707e0.html

参考怎么安装nodejs v4.0.0 x64: http://jingyan.baidu.com/article/a948d6515d4c850a2dcd2e18.html

安装了nodejs后可以写一个test.js测试文件:

1 var http=require("http");
2 http.createServer(function(request,response){
3     response.writeHead(200,{"Content-Type":"text/plain"});
4     response.write("test nodejs");
5     response.end();
6 }).listen(8899);
7 
8 console.log("nodejs start listen 8899 port!");

在浏览器中输入http://localhost:8899,回车;

好了,nodejs已经安装好了,感觉nodejs还是挺简单的。

安装了nodejs后,可以在cmd中使用npm命令安装phonegap:

Install PhoneGap

To Install, ensure that you have NodeJS installed, then open your command-line and run the following:

C:\> npm install -g phonegap            

Once installation completes, you can invoke phonegap on command line for further help.


Usage

$ phonegap create my-app
$ cd my-app
$ phonegap run android        

Learn more at docs.phonegap.com

Looking for an easier way to get started? Try the new PhoneGap Desktop App (in beta)!

 

别人写的团购开源app,收藏下:http://www.cnblogs.com/archy_yu/p/4811600.html

转载于:https://www.cnblogs.com/yy3b2007com/p/4811851.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值