1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2025-01-24 13:38:18 +01:00
phorge-arcanist/src/lint/linter/reporter.js

20 lines
532 B
JavaScript
Raw Normal View History

module.exports = {
reporter: function (results) {
var report = [];
results.forEach(function (result) {
var error = result.error;
report.push({
'file' : result.file,
'line' : error.line,
'col' : error.character,
'reason' : error.reason,
'code' : error.code,
'evidence': error.evidence,
});
});
process.stdout.write(JSON.stringify(report));
}
};