Displaying error when regex does not match. On my ubuntu when `android` is not found typical output is:
``` /bin/sh: 1: android: not found ``` close #104 Project: http://git-wip-us.apache.org/repos/asf/cordova-amazon-fireos/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-amazon-fireos/commit/6e830fcc Tree: http://git-wip-us.apache.org/repos/asf/cordova-amazon-fireos/tree/6e830fcc Diff: http://git-wip-us.apache.org/repos/asf/cordova-amazon-fireos/diff/6e830fcc Branch: refs/heads/master Commit: 6e830fcc16d21f7dd0a2468d74a9e908ae4b4017 Parents: b83d7ab Author: Ankit Jain <[email protected]> Authored: Mon Jun 30 23:59:53 2014 +0530 Committer: Archana Naik <[email protected]> Committed: Wed Jul 30 18:06:02 2014 -0700 ---------------------------------------------------------------------- bin/lib/check_reqs.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-amazon-fireos/blob/6e830fcc/bin/lib/check_reqs.js ---------------------------------------------------------------------- diff --git a/bin/lib/check_reqs.js b/bin/lib/check_reqs.js index b15a9b6..397283e 100644 --- a/bin/lib/check_reqs.js +++ b/bin/lib/check_reqs.js @@ -85,7 +85,7 @@ module.exports.check_android = function() { if (stderr.match(/command\snot\sfound/)) { return Q.reject(new Error('The command \"android\" failed. Make sure you have the latest Android SDK installed, and the \"android\" command (inside the tools/ folder) is added to your path.')); } else { - return Q.reject(new Error('An error occurred while listing Android targets')); + return Q.reject(new Error('An error occurred while listing Android targets. Error: ' + stderr )); } }); }
