You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Lorin Beer (JIRA)" <ji...@apache.org> on 2014/06/19 22:20:24 UTC
[jira] [Updated] (CB-6985) [android] check requirements broken
[ https://issues.apache.org/jira/browse/CB-6985?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Lorin Beer updated CB-6985:
---------------------------
Description:
CLI attempts to create android project even when SDK/env-vars are not present.
steps to replicate
1. remove 'android' tool from path
2. $ cordova create foo && cd foo
3. $ cordova platform add android
depending on what you removed from your path (android, android tools, ant, etc) the output looks something like this
'''
Creating android project...
/Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/node_modules/q/q.js:126
throw e;
^
Error: ERROR : executing command 'ant', make sure you have ant installed and added to your path.
at /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/lib/check_reqs.js:47:27
at ChildProcess.exithandler (child_process.js:651:7)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:753:16)
at Socket.<anonymous> (child_process.js:966:11)
at Socket.EventEmitter.emit (events.js:95:17)
at Pipe.close (net.js:465:12)
Error: /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/create: Command failed with exit code 8
at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:131:23)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:753:16)
at Process.ChildProcess._handle.onexit (child_process.js:820:5)
### solution
fix so error are not generated by attempting to create platform projects when the platform is invalid for the dev OS or not present.
was:
CLI attempts to create android project even when SDK/env-vars are not present.
### steps to replicate
1. remove 'android' tool from path
2. $ cordova create foo && cd foo
3. $ cordova platform add android
depending on what you removed from your path (android, android tools, ant, etc) the output looks something like this
'''
Creating android project...
/Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/node_modules/q/q.js:126
throw e;
^
Error: ERROR : executing command 'ant', make sure you have ant installed and added to your path.
at /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/lib/check_reqs.js:47:27
at ChildProcess.exithandler (child_process.js:651:7)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:753:16)
at Socket.<anonymous> (child_process.js:966:11)
at Socket.EventEmitter.emit (events.js:95:17)
at Pipe.close (net.js:465:12)
Error: /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/create: Command failed with exit code 8
at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:131:23)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:753:16)
at Process.ChildProcess._handle.onexit (child_process.js:820:5)
### solution
fix so error are not generated by attempting to create platform projects when the platform is invalid for the dev OS or not present.
> [android] check requirements broken
> -----------------------------------
>
> Key: CB-6985
> URL: https://issues.apache.org/jira/browse/CB-6985
> Project: Apache Cordova
> Issue Type: Bug
> Components: CLI
> Affects Versions: 3.5.0
> Reporter: Lorin Beer
> Assignee: Lorin Beer
>
> CLI attempts to create android project even when SDK/env-vars are not present.
> steps to replicate
> 1. remove 'android' tool from path
> 2. $ cordova create foo && cd foo
> 3. $ cordova platform add android
> depending on what you removed from your path (android, android tools, ant, etc) the output looks something like this
> '''
> Creating android project...
> /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/node_modules/q/q.js:126
> throw e;
> ^
> Error: ERROR : executing command 'ant', make sure you have ant installed and added to your path.
> at /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/lib/check_reqs.js:47:27
> at ChildProcess.exithandler (child_process.js:651:7)
> at ChildProcess.EventEmitter.emit (events.js:98:17)
> at maybeClose (child_process.js:753:16)
> at Socket.<anonymous> (child_process.js:966:11)
> at Socket.EventEmitter.emit (events.js:95:17)
> at Pipe.close (net.js:465:12)
> Error: /Users/lorin/.cordova/lib/android/cordova/3.5.0/bin/create: Command failed with exit code 8
> at ChildProcess.whenDone (/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:131:23)
> at ChildProcess.EventEmitter.emit (events.js:98:17)
> at maybeClose (child_process.js:753:16)
> at Process.ChildProcess._handle.onexit (child_process.js:820:5)
> ### solution
> fix so error are not generated by attempting to create platform projects when the platform is invalid for the dev OS or not present.
--
This message was sent by Atlassian JIRA
(v6.2#6252)