mirror of
https://github.com/apache/cordova-android.git
synced 2025-01-19 07:02:51 +08:00
1.6 KiB
1.6 KiB
PhoneGap/Android
PhoneGap/Android is an Android application library that allows for PhoneGap based projects to be built for the Android Platform. PhoneGap based applications are, at the core, an application written with web technology: HTML, CSS and JavaScript.
Pre Requisites
- Java JDK 1.5
- Android SDK http://developer.android.com
- Apache ANT
PhoneGap/Android Developer Tools
Tools for developers building mobile apps using PhoneGap for Android.
Commands:
./bin/create [path package activity]
./bin/debug [path]
./bin/emulate
./bin/log
Importing a PhoneGap/Android app into Eclipse
- File > New > Project...
- Android > Android Project
- Create project from existing source (point to the generated app found in tmp/android)
- Right click on libs/phonegap.jar and add to build path
- Right click on the project root: Run as > Run Configurations
- Click on the Target tab and select Manual (this way you can choose the emulator or device to build to)
Common Commandline Tools
List devices attached
adb devices
Install APK onto device
apk -s 0123456789012 install phonegap.apk
Logging
Via console.log calls from your apps javascript.
adb logcat
Debugging
Attach it to a process on the device
$ adb jdwp
adb forward tcp:8000 jdwp: jdb -attach localhost:8000