Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VS2013 Cordova blank app command failed with exit code 8 error

I've create a new Blank App (Apache Cordova) typescript in VS2013 community edition. Running the ripple emulator works fine. But when I attempt to run the android emulator or device, then I get this error:

C:\WorkspaceMobileVisualStudio\BlankCordovaApp1\BlankCordovaApp1\bld\Debug\platforms\android\cordova\build.bat: Command failed with exit code 8 C:\WorkspaceMobileVisualStudio\BlankCordovaApp1\BlankCordovaApp1\MDAVSCLI

The output is:

1>------ Build started: Project: BlankCordovaApp1, Configuration: Debug Android 1> GeneratedJavascript=scripts\index.js;scripts\platformOverrides.js 1> C:\WorkspaceMobileVisualStudio\BlankCordovaApp1\BlankCordovaApp1>call "C:\Program Files (x86)\nodejs\"\nodevars.bat 1> Your environment has been set up for using Node.js 0.10.33 (ia32) and npm. 1> ------ Ensuring correct global installation of package from source package directory: C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\COMMON7\IDE\EXTENSIONS\1LHTZMLE.C0Y\packages\vs-mda 1>MDAVSCLI : error : C:\WorkspaceMobileVisualStudio\BlankCordovaApp1\BlankCordovaApp1\bld\Debug\platforms\android\cordova\build.bat: Command failed with exit code 8 ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ========== ========== Deploy: 0 succeeded, 0 failed, 0 skipped ==========

I have seen questions where the answer has been to check path variables JAVA_HOME, ADT_HOME, and ANT_HOME, which I have done, and they are all correct. The other common issue appears to be spaces in the workspace, which I did have, but I've now created a new workspace folder.

As far as I'm aware I should be able to see the "Hello, your application is ready!" screen.

like image 362
Richard Pike Avatar asked Feb 19 '15 11:02

Richard Pike


1 Answers

Turned out to be an issue with the Node.js version I was using: 0.12. I uninstalled this and ran the .msi installer for version 0.10.28 from here: http://nodejs.org/dist/v0.10.28/

Worth noting that this still does not like numbers or spaces in the workspace directory!

like image 100
Richard Pike Avatar answered Nov 17 '22 20:11

Richard Pike