<commit_before>var gulp = require('gulp');
var del = require('del');
var shell = require('shelljs');
var bump = require('gulp-bump');
var util = require('util');

var config = {
    wowAddonDir: 'C:/Program Files (x86)/World of Warcraft/Interface/AddOns/StatWeightScore',
    src: 'src/**/*.{lua,xml,toc}'
};

gulp.task('clean-local', function(cb){
    del([util.format('%s/**/*', config.wowAddonDir)], { force: true }, cb);
})

gulp.task('publish-local', ['clean-local'], function(){
    return gulp
        .src(config.src)
        .pipe(gulp.dest(config.wowAddonDir));
});

gulp.task('watch', ['publish-local'], function(){
    gulp.watch(config.src, ['publish-local'])
});

gulp.task('_bump', function(){
    var argv = require('yargs')
        .alias('v', 'version')
        .alias('t', 'type')
        .check(function(argv){
            if((!argv.version && !argv.type) || (argv.version && argv.type)){
                throw 'Exactly one of version or type arguments is required';
            }

            return true;
        })
        .argv;
        
    var bumpOptions = {
        preid: 'rc'
    };
    
    if(argv.version){
        bumpOptions.version = argv.version;
    } else if(argv.type){
        bumpOptions.type = argv.type;
    }
    
    return gulp
        .src('package.json')
        .pipe(bump(bumpOptions))
        .pipe(gulp.dest('.'));
});

gulp.task('release', ['_bump'], function(){
    var version = require('./package.json').version;
    
    shell.exec(util.format('git commit -a -m "Release v%s"', version));
    shell.exec(util.format('git tag %s', version));
    shell.exec('git push origin master');
    shell.exec('git checkout curse');
    shell.exec('git pull curse master');
    shell.exec('git merge master');
    shell.exec('git push curse master');
    shell.exec('git push --tags');
    
    console.log(util.format('Release %s completed', version));
});<commit_msg>Simplify release task further<commit_after>var gulp = require('gulp');
var del = require('del');
var shell = require('shelljs');
var bump = require('gulp-bump');
var util = require('util');

var config = {
    wowAddonDir: 'C:/Program Files (x86)/World of Warcraft/Interface/AddOns/StatWeightScore',
    src: 'src/**/*.{lua,xml,toc}'
};

gulp.task('clean-local', function(cb){
    del([util.format('%s/**/*', config.wowAddonDir)], { force: true }, cb);
})

gulp.task('publish-local', ['clean-local'], function(){
    return gulp
        .src(config.src)
        .pipe(gulp.dest(config.wowAddonDir));
});

gulp.task('watch', ['publish-local'], function(){
    gulp.watch(config.src, ['publish-local'])
});

gulp.task('_bump', function(){
    var argv = require('yargs')
        .alias('v', 'version')
        .alias('t', 'type')
        .check(function(argv){
            if((!argv.version && !argv.type) || (argv.version && argv.type)){
                throw 'Exactly one of version or type arguments is required';
            }

            return true;
        })
        .argv;
        
    var bumpOptions = {
        preid: 'rc'
    };
    
    if(argv.version){
        bumpOptions.version = argv.version;
    } else if(argv.type){
        bumpOptions.type = argv.type;
    }
    
    return gulp
        .src('package.json')
        .pipe(bump(bumpOptions))
        .pipe(gulp.dest('.'));
});

gulp.task('release', ['_bump'], function(){
    var version = require('./package.json').version;
    
    shell.exec(util.format('git commit -a -m "Release v%s"', version));
    shell.exec(util.format('git tag %s', version));
    shell.exec('git push origin master');
    
    console.log(util.format('Release %s completed', version));
});
{'fraction_non_alphanumeric': 0.19151846785225718, 'fraction_numerical': 0.001094391244870041, 'mean_word_length': 2.753593429158111, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '6287889', 'n_tokens_mistral': 1192, 'n_tokens_neox': 1180, 'n_words': 244}