<commit_before>var gulp = require('gulp');
var concat = require('gulp-concat');
var sourcemaps = require('gulp-sourcemaps');
var del = require('del');
var browserSync  = require('browser-sync').create();
var iife  = require('gulp-iife');

var paths = {
  scripts: ['src/scripts/*.js']
};

gulp.task('clean', function() {
  return del(['build']);
});

gulp.task('scripts', ['clean'], function() {
  return gulp.src(paths.scripts)
    .pipe(sourcemaps.init())
    .pipe(concat("sdk.js"))
    .pipe(iife({
                 params: ["window"],
                 args: ["window"]
               }))
    .pipe(sourcemaps.write("."))
    .pipe(gulp.dest("dist"));
});

gulp.task('watch', function() {
  gulp.watch(paths.scripts, ['scripts']);
});

// gulp.task('watch', function() {
//   browserSync.init({
//                      proxy: config.devUrl,
//                      port: 8080
//                    });
//   gulp.watch([path.source + 'app/assets/styles/**/*'], ['styles']);
//   gulp.watch([path.source + 'app/modules/**/*'], ['jshint', 'scripts']);
//   gulp.watch([path.source + 'app/templates/**/*'], ['templates']);
// });
gulp.task('default', ['watch', 'scripts']);<commit_msg>gulp: clean and add 'build' task<commit_after>var gulp = require('gulp');
var concat = require('gulp-concat');
var sourcemaps = require('gulp-sourcemaps');
var del = require('del');
var iife  = require('gulp-iife');
var uglify = require('gulp-uglify');
var gulpSequence = require('gulp-sequence');
var rename = require("gulp-rename");

var paths = {
  scripts: ['src/scripts/*.js'],
  dist: ['dist/']
};

gulp.task('clean', function() {
  return del(['dist']);
});

gulp.task('scripts', ['clean'], function() {
  return gulp.src(paths.scripts)
    .pipe(sourcemaps.init())
    .pipe(concat("sdk.js"))
    .pipe(iife({
                 params: ["window"],
                 args: ["window"]
               }))
    .pipe(sourcemaps.write("."))
    .pipe(gulp.dest("dist"));
});

gulp.task('uglify', function() {
  return gulp.src(paths.dist + 'sdk.js')
    .pipe(rename("sdk.min.js"))
    .pipe(uglify())
    .pipe(gulp.dest("dist"));
});

gulp.task('watch', function() {
  gulp.watch(paths.scripts, ['scripts']);
});

gulp.task('build', gulpSequence('scripts', 'uglify'));

gulp.task('default', ['build']);
{'fraction_non_alphanumeric': 0.23765836609873306, 'fraction_numerical': 0.0017474879860200961, 'mean_word_length': 3.232902033271719, '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': '2517138', 'n_tokens_mistral': 775, 'n_tokens_neox': 767, 'n_words': 133}