Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
CB-5182 Adding generic error case to run script
Reviewed by Bryan Higgins <bhiggins@blackberry.com>
  • Loading branch information
Jeffrey Heifetz authored and bryanhiggins committed Oct 28, 2013
1 parent c6de78e commit 7ec40a878f2f72c4c4de10158912c480143dba97
Showing 1 changed file with 5 additions and 4 deletions.
@@ -21,7 +21,8 @@ var path = require("path"),
options = require('commander'),
runUtils = require("./run-utils"),
logger = require("./logger"),
async = require("async");
async = require("async"),
ERROR_CODE = 2;

function install(deployTarget, done) {
var buildCmd = utils.isWindows() ? "build" : "./build",
@@ -77,10 +78,10 @@ async.waterfall(
if (err) {
if (typeof err === "string") {
logger.error(err);
process.exit(1);
} else if (typeof err === "number") {
process.exit(err);
} else {
logger.error("An error has occurred");
}
process.exit(ERROR_CODE);
} else {
process.exit(0);
}

0 comments on commit 7ec40a8

Please sign in to comment.