Phonegap 3 does not work with Android Studio

It seems pretty simple to me, but I can't do it at all.

I have npm install -g phonegap with everything successful and installing a telephone plug.

I follow the instructions from here http://phonegap.com/install/ . Then I created my project:

 C:\var\www\sexdiaries.co.uk>phonegap create sexdiaries -n SexDiaries -i co.uk.sexdiaries.app 

I then, as said here, tried to run andriod, but with the following errors

 C:\var\www\sexdiaries.co.uk\sexdiaries>phonegap run andriod C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\lib\phonegap\run.js:72 self.phonegap.emit('log', 'detecting', platform.human, 'SDK environment... ^ TypeError: Cannot read property 'human' of undefined at RunCommand.execute (C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\lib\phonegap\run.js:72:52) at RunCommand.run (C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\lib\phonegap\run.js:55:10) at PhoneGap.run (C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\lib\phonegap\util\command.js:28:25) at CLI.module.exports [as run] (C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\lib\cli\run.js:38:14) at CLI.module.exports [as argv] (C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\lib\cli\argv.js:66:17) at Object.<anonymous> (C:\Users\Hutber\AppData\Roaming\npm\node_modules\phonegap\bin\phonegap.js:24:21) at Module._compile (module.js:456:26) at Object.Module._extensions..js (module.js:474:10) at Module.load (module.js:356:32) at Function.Module._load (module.js:312:12) 

In addition, I imported the project created in Andriod Studio, but at the same time I get: Source files for your project not found

I know how to create a working project using phonegap 2.9. But can't decide what 3 offers?

So the question is, how can I get a valid local Android app using phoengap 3

+1
android android-studio cordova
source share
3 answers

After digging, I found how to get past this:

 phonegap run android 

It is so simple.

[change]

You need to add a platform to work while the documentation is so very poor:

 C:\var\www\sexdiaries.co.uk\sexdiaries>phonegap build android [phonegap] detecting Android SDK environment... [phonegap] using the local environment [phonegap] adding the Android platform... [warning] missing library cordova/android/3.0.0 [phonegap] downloading https://git-wip-us.apache.org/repos/asf?p=cordova-android.git;a=snapshot;h=3.0.0;sf=tgz... [phonegap] compiling Android... [phonegap] successfully compiled Android app 

Then you should go, now importing with Andriod Studio will also work, since you have a project to work with :)

Fantastic.

+2
source share

The command is "Android browser", "Does not work", and "phonegap run andriod". Try it again. I had a problem like you.

+10
source share

I used phonegap 3.0 with Android Studio and it works great. Please go this

+2
source share

All Articles