mirror of https://github.com/embarklabs/embark.git
advice user when an unknown command is typed in the console
This commit is contained in:
parent
a511979cd1
commit
bd99a75048
|
@ -36,7 +36,11 @@ Console.prototype.executeCmd = function(cmd, callback) {
|
||||||
return callback(result);
|
return callback(result);
|
||||||
}
|
}
|
||||||
catch(e) {
|
catch(e) {
|
||||||
return callback(e.message.red);
|
if (e.message.indexOf('not defined') > 0) {
|
||||||
|
return callback(("error: " + e.message).red + ("\nType " + "help".bold + " to see the list of available commands").cyan);
|
||||||
|
} else {
|
||||||
|
return callback(e.message);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue