Skip to content

Commit

Permalink
Merge pull request #85 from codeclimate/pb-custom-config
Browse files Browse the repository at this point in the history
Delay instantiation of cli variable
  • Loading branch information
pbrisbin committed Mar 16, 2016
2 parents 3bca438 + 5c7a2ec commit 85b96d8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion bin/eslint.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ var docs = require("eslint").docs;
var fs = require("fs");
var glob = require("glob");
var options = { extensions: [".js"], ignore: true, reset: false, useEslintrc: true };
var cli = new CLIEngine(options);
var cli; // instantiation delayed until after options are (potentially) modified
var debug = false;
var checks = require("../lib/checks");
var validateConfig = require("../lib/validate_config");
Expand Down Expand Up @@ -160,6 +160,8 @@ runWithTiming("engineConfig", function () {
debug = true;
}
}

cli = new CLIEngine(options);
});

var analysisFiles = runWithTiming("buildFileList", function() {
Expand Down

0 comments on commit 85b96d8

Please sign in to comment.