Archive for October 27th, 2014
27
Oct
Phonegap - Hellow world
download android sdk, adt, unzip vao c:\adt
$ android create avd –name avd19 –target android-19
download nodejs http://nodejs.org/download/ , chon windows bin 32 hoac 64 bits, copy vao c:\adt\node.exe
download npm, http://nodejs.org/dist/npm/ , unzip vao c:\adt\
download http://ant.apache.org/ , unzip vao c:\adt\ant , set PATH=c:\adt\ant\bin
C:\> npm install -g phonegap
$ phonegap create my-app
$ cd my-app
$ phonegap install android
$ phonegap run android
$ plugman install –platform android –project “c:\adt\my-app\platforms\android” –plugin org.apache.cordova.device
$ phonegap local plugin add org.apache.cordova.device
DEBUG tool
$
npm -g install weinre
$ weinre --boundHost yourIP
open web http://yourIP:8080/client
put this line to www/index.html
<script src="http://yourIP:8080/target/target-script-min.js"></script>