opter
Version:
A Node JS wrapper around commander to allow for easy commandline and env var parsing
19 lines (16 loc) • 527 B
JavaScript
module.exports = {
reporter: function reporter(results) {
var len = results.length,
str = '',
file, error;
results.forEach(function (result) {
file = result.file;
error = result.error;
str += file + ': line ' + error.line + ', col ' +
error.character + ', ' + error.reason + '\n';
});
if (str) {
process.stdout.write(str + "\n" + len + ' error' + ((len === 1) ? '' : 's') + "\n");
}
}
};