shelljs/test/utils/utils.js
Nate Fischer 74f1ff8748 Commands that have multiple errors now produce cleaner log output. Errors are
echoed to stderr. exec() supports a new stderr field.
2016-01-12 17:02:19 -08:00

6 lines
131 B
JavaScript

function _numLines(str) {
return typeof str === 'string' ? (str.match(/\n/g)||[]).length+1 : 0;
}
exports.numLines = _numLines;