<commit_before>#!/usr/bin/env node

// Set up logger before doing anything else, so that modules that
// require it can use it immediately
var config = require('config'),
    winston = require('winston');

var log = new winston.Logger({
    transports: [
        new winston.transports.Console({
            colorize: true,
            level: ((config.logging ? config.logging.level : null) || 'http')
        })
    ]
});
log.cli();
log.levels.http = 4.5;
log.setLevels(log.levels);
winston.addColors({ http: 'grey' });
log.extend(require('./lib/logger'));

var appRoutes      = require('./lib/routes'),
    consolidate    = require('consolidate'),
    express        = require('express'),
    expressWinston = require('./lib/vendor/express-winston'),
    path           = require('path'),
    swig           = require('swig');

require('express-namespace');

var app = express();<commit_msg>Modify log.{info,...} methods to behave the same as log.log<commit_after>#!/usr/bin/env node

// Set up logger before doing anything else, so that modules that
// require it can use it immediately
var config = require('config'),
    winston = require('winston');

var log = new winston.Logger({
    transports: [
        new winston.transports.Console({
            colorize: true,
            level: ((config.logging ? config.logging.level : null) || 'http')
        })
    ]
});
log.cli();
log.levels.http = 4.5;
log.setLevels(log.levels);
winston.addColors({ http: 'grey' });

// Modify log.{info,...} methods to be the same as log.log({'info',...}, ...)
for (var level in log.levels) {
    (function(level) {
        log[level] = function() {
            log.log.apply(log,
                [level].concat(Array.prototype.slice.call(arguments)));
        };
    })(level);
}

// Make logging available as var log = require('./lib/logger');
log.extend(require('./lib/logger'));

var appRoutes      = require('./lib/routes'),
    consolidate    = require('consolidate'),
    express        = require('express'),
    expressWinston = require('./lib/vendor/express-winston'),
    path           = require('path'),
    swig           = require('swig');

require('express-namespace');

var app = express();
{'fraction_non_alphanumeric': 0.16894353369763207, 'fraction_numerical': 0.0018214936247723133, 'mean_word_length': 2.749146757679181, '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': '5744581', 'n_tokens_mistral': 670, 'n_tokens_neox': 649, 'n_words': 160}