4

I have a Phonegap 3.3.0 project set up and working perfectly as much as that I can build an .APK from the cmd at pat:

jamie@Hutber-8 /c/var/www/sexdiaries.co.uk/sdapp/app
  $ phonegap build android
    [phonegap] detecting Android SDK environment...
    [phonegap] using the local environment
    [phonegap] compiling Android...
    [phonegap] successfully compiled Android app

I have my Phone plugged in, its a nexus 5 which seems to have problems with windows 8, but I believe its working correctly:

$ adb devices
List of devices attached
029188d8e0784684        device

However when I try to deploy to this device:

$ phonegap install android
[phonegap] detecting Android SDK environment...
[phonegap] using the local environment
[phonegap] trying to install app onto device
[phonegap] no device was found
[phonegap] trying to install app onto emulator
   [error] An error occurred while emulating/deploying the android project.
events.js:72
        throw er; // Unhandled 'error' event
              ^
Error: spawn ENOENT
    at errnoException (child_process.js:980:11)

I've looked through the documentation but can't seem to find details on this...

Jamie Hutber
  • 26,790
  • 46
  • 179
  • 291
  • did you enable usb debuging on the nexus 5? do other commands like adb logcat work? – QuickFix Jan 15 '14 at 00:10
  • I believe I have, as adb reconises the device, although drivers for windows 8.1 seem rather scarce, I've got the device reporting as `Android Composite ADB Interface` but yes, adb logcat works and displays, well the log :) – Jamie Hutber Jan 15 '14 at 09:03
  • I'm using windows 8.1 with samsung android 2.3 and Motorola android 4.1 with no issue, but with specific drivers. So maybe it's something to do with the nexus 5 or the google driver, but it's more something we would expect from an exotic chinese phone, not much from a nexus :( Do you have the latest driver? (ok, stupid question ;) ) – QuickFix Jan 15 '14 at 10:16
  • you can try to have a look at this post : http://stackoverflow.com/questions/19886456/nexus-5-kitkat-4-4-wont-authorize-my-windows-8-computer – QuickFix Jan 15 '14 at 10:16
  • Humm I installed this at work on Windows 7 and it also displays two devices, one is the `android ADB interface` and the other is `Nexus 5` in`portable devices` In windows 8.1 I have to do to `update drivers -> show compatible devices -> show all -> have disk` and then manually select the driver. I can't just point it to the directory. In otherwords, I think the drivers a little bit rubbish for 8.1. But i will try the removing trick again (which I have already :)) – Jamie Hutber Jan 15 '14 at 16:27

1 Answers1

3

It turned out that everything was running correctly, the only problem was that I had previously installed the app, under the same name but signed different.

Put simply, uninstall the same app, or previously installed app and then this command will work:

phonegap run android

Jamie Hutber
  • 26,790
  • 46
  • 179
  • 291