<commit_before>'use strict';

const colors = require('ansicolors');
const fs = require('fs');
const pluralize = require('pluralize');
const CLIEngine = require('eslint').CLIEngine;

class ESLinter {
  constructor(brunchConfig) {
    this.config   = (brunchConfig && brunchConfig.plugins && brunchConfig.plugins.eslint) || {};
    this.warnOnly = (this.config.warnOnly === true);
    this.pattern  = this.config.pattern || /^app[\/\\].*\.js?$/;

    const engineConfig = {};

    this.linter = new CLIEngine(engineConfig);
  }

  lint(data, path) {
    const result = this.linter.executeOnText(data, path).results[0];<commit_msg>Correctly implement configuration of CLIEngine options<commit_after>'use strict';

const colors = require('ansicolors');
const fs = require('fs');
const pluralize = require('pluralize');
const CLIEngine = require('eslint').CLIEngine;

class ESLinter {
  constructor(brunchConfig) {
    this.config   = (brunchConfig && brunchConfig.plugins && brunchConfig.plugins.eslint) || {};
    this.warnOnly = (this.config.warnOnly === true);
    this.pattern  = this.config.pattern || /^app[\/\\].*\.js?$/;
    this.engineOptions = this.config.config || {};
    this.linter = new CLIEngine(this.engineOptions);
  }

  lint(data, path) {
    const result = this.linter.executeOnText(data, path).results[0];
{'fraction_non_alphanumeric': 0.16628873771730915, 'fraction_numerical': 0.0015117157974300832, 'mean_word_length': 4.317269076305221, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2413817', 'n_tokens_mistral': 427, 'n_tokens_neox': 410, 'n_words': 80}