Skip to content

Commit

Permalink
[ux][api]support info on jitsu error and reduced error output for 'so…
Browse files Browse the repository at this point in the history
…cket hand up'
  • Loading branch information
blakmatrix committed Aug 22, 2012
1 parent f445e23 commit 551c7d8
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions lib/jitsu.js
Expand Up @@ -344,12 +344,21 @@ jitsu.showError = function (command, err, shallow, skip) {
}
else {
if (err.stack && !shallow) {
err.stack.split('\n').forEach(function (trace) {
jitsu.log.error(trace);
});
if(err.message && err.message === 'socket hang up'){
//nothing
} else {
err.stack.split('\n').forEach(function (trace) {
jitsu.log.error(trace);
});
}
}
}
}

jitsu.log.help("For help with this error contact Nodejitsu Support:");
jitsu.log.help(" webchat: <http://webchat.nodejitsu.com/>");
jitsu.log.help(" irc: <irc://chat.freenode.net/#nodejitsu>");
jitsu.log.help(" email: <support@nodejitsu.com>");
jitsu.log.help("");
jitsu.log.help(" Copy and paste this output to a gist (http://gist.github.com/)");
jitsu.log.info('Nodejitsu '.grey + 'not ok'.red.bold);
};

0 comments on commit 551c7d8

Please sign in to comment.