diff --git a/BuildServer/lib/tasks/dotnetcheckstyle.js b/BuildServer/lib/tasks/dotnetcheckstyle.js index d3d2c97..6e51a11 100644 --- a/BuildServer/lib/tasks/dotnetcheckstyle.js +++ b/BuildServer/lib/tasks/dotnetcheckstyle.js @@ -4,6 +4,10 @@ var fs = require('fs'); var async = require('async'); var glob = require('glob'); +var autoGeneratedMarker = + "//------------------------------------------------------------------------------" + "\n" + + "// "; + module.exports = function (params, processor) { return { process: function () { @@ -33,6 +37,8 @@ module.exports = function (params, processor) { processor.onError("Unable to check file " + file + ": " + err); } else if (data.indexOf("\r\n") >= 0) { processor.onError("Windows-style EOL (0D0A) found in file " + file); + } else if (data.substr(1, autoGeneratedMarker.length) === autoGeneratedMarker || data.substr(0, autoGeneratedMarker.length) === autoGeneratedMarker) { + processor.onInfo("Skipping auto-generated file " + file); } else if (data.indexOf("\t") >= 0 && data.indexOf(" ") >= 0) { processor.onError("Both tabs and spaces found in file " + file); } else {