<commit_before>var watch = require('node-watch');

function initConfig(config) {
    config.configFile = config.configFile ? config.configFile : 'package.json';
    config.tempFolder = config.tempFolder ? config.tempFolder : 'dist';
    config.browserify = config.browserify ? config.browserify : true;
    config.rootFile = config.rootFile ? config.rootFile : 'boot';
    config.dest = config.dest ? config.dest : 'script.js';
}

module.exports = function(config) {
    return {
        prodRun: function(config) {
            initConfig(config);

            config.exec('tsc --p ' + config.configFile, () => {
                var srcFile = config.tempFolder + '/' + config.rootFile + '.js';
                console.log(' [ ] ' + config.dest + ' updating from ' + srcFile);
                config.exec('browserify -s main ' + srcFile + ' -o ' + config.dest, () => {
                    console.log(' [o] ' + config.dest + ' updated');
                });
            });
        },
        devRun: function(config) {
            initConfig(config);

            config.exec('tsc --p ' + config.configFile + ' --watch');

            if(!config.browserify)
                return;

            var countOut = 0;
            config.watch(config.tempFolder, { recursive: true }, function(event, filename) {
                ++countOut;
                setTimeout(function() {
                    if(--countOut > 0)
                        return;
                    var srcFile = config.tempFolder + '/' + config.rootFile + '.js';
                    console.log(' [ ] ' + config.dest + ' updating from ' + srcFile);
                    config.exec('browserify -s main ' + srcFile + ' -o ' + config.dest, () => {
                        console.log(' [o] ' + config.dest + ' updated');
                    });
                }, 200);
            });
        },
        clean: (config) => {
            initConfig(config);
            config.rmdir(config.tempFolder);
        },
        configSample: {
            type: 'typescript',
            tempFolder: 'react/bin',
            rootFile: 'root',
            dest: 'public/react.js',
            browserify: true
        }
    }
}<commit_msg>Added more verbosity<commit_after>var watch = require('node-watch');

function initConfig(config) {
    config.configFile = config.configFile ? config.configFile : 'package.json';
    config.tempFolder = config.tempFolder ? config.tempFolder : 'dist';
    config.browserify = config.browserify ? config.browserify : true;
    config.rootFile = config.rootFile ? config.rootFile : 'boot';
    config.dest = config.dest ? config.dest : 'script.js';
}

module.exports = function(config) {
    return {
        prodRun: function(config) {
            initConfig(config);

            config.exec('tsc --p ' + config.configFile, () => {
                var srcFile = config.tempFolder + '/' + config.rootFile + '.js';
                console.log(' [ ] ' + config.dest + ' updating from ' + srcFile);
                config.exec('browserify -s main ' + srcFile + ' -o ' + config.dest, () => {
                    console.log(' [o] ' + config.dest + ' updated');
                });
            });
        },
        devRun: function(config) {
            initConfig(config);

            config.exec('tsc --p ' + config.configFile + ' --watch');

            if(!config.browserify)
                return;

            var countOut = 0;
            config.watch(config.tempFolder, { recursive: true }, function(event, filename) {
                ++countOut;
                setTimeout(function() {
                    if(--countOut > 0)
                        return;
                    var srcFile = config.tempFolder + '/' + config.rootFile + '.js';
                    console.log(' [o] ' + filename + ' updated');
                    console.log(' [ ] compiling ' + srcFile + ' to ' + config.dest);
                    config.exec('browserify -s main ' + srcFile + ' -o ' + config.dest, () => {
                        console.log(' [o] ' + config.dest + ' updated');
                    });
                }, 200);
            });
        },
        clean: (config) => {
            initConfig(config);
            config.rmdir(config.tempFolder);
        },
        configSample: {
            type: 'typescript',
            tempFolder: 'react/bin',
            rootFile: 'root',
            dest: 'public/react.js',
            browserify: true
        }
    }
}
{'fraction_non_alphanumeric': 0.1447132616487455, 'fraction_numerical': 0.002240143369175627, 'mean_word_length': 1.5369318181818181, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 13, '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': '2100684', 'n_tokens_mistral': 1234, 'n_tokens_neox': 1180, 'n_words': 230}