var gulp = require('gulp'),
    rollup = require('rollup'),
    browserSync = require('browser-sync'),
    uglify = require('gulp-uglify'),
    minifyCss = require('gulp-minify-css');

gulp.task('compress', function() {
  return gulp.src('lib/*.js')
    .pipe(uglify())
    .pipe(gulp.dest('dist'));
});



var ENTRY = 'src/js/main.js';
var DEST = 'js/main.js';

gulp.task('bundle', function() {
    return rollup.rollup({
        entry: ENTRY
    }).then(function (bundle) {
        return bundle.write({
            format: 'iife',
            dest: DEST
        });
    });
});

gulp.task('minify-css', function() {
    return gulp.src('src/styles/*.css')
        .pipe(minifyCss())
        .pipe(gulp.dest('./styles'));
});

gulp.task('minify-js', ['bundle'], function() {
    return gulp.src('js/*.js')
        .pipe(uglify())
        .pipe(gulp.dest('js'));
});

gulp.task('default', ['minify-css', 'minify-js']);

gulp.task('build-and-reload', ['minify-css', 'bundle'], function () {
    browserSync.reload();
});

gulp.task('serve', function(cb) {
  browserSync({
    server: {
      baseDir: './'
    },
    notify: false,
    ui: false,
    ghostMode: false
  });

  gulp.watch(['*.html', 'styles/**/*.css', 'js/**/*.js'], {cwd: 'src'}, ['build-and-reload']);
});

@@ -182,130 +182,8 @@
 );%0A%0A
-gulp.task('compress', function() %7B%0A  return gulp.src('lib/*.js')%0A    .pipe(uglify())%0A    .pipe(gulp.dest('dist'));%0A%7D);%0A%0A%0A%0A
 var 
@@ -315,16 +315,20 @@
 : ENTRY%0A
+    
     %7D).t
@@ -355,24 +355,28 @@
 ) %7B%0A        
+    
 return bundl
@@ -397,16 +397,20 @@
         
+  
+  
 format: 
@@ -429,16 +429,20 @@
         
+    
 dest: DE
@@ -456,16 +456,24 @@
     
+    
+    
 %7D);%0A    
 %7D);%0A
@@ -468,20 +468,36 @@
 %7D);%0A    
-%7D);%0A
+        %7D);%0A        
 %7D);%0A%0Agul
@@ -566,28 +566,24 @@
 les/*.css')%0A
-    
     .pipe(mi
@@ -589,28 +589,24 @@
 inifyCss())%0A
-    
     .pipe(gu
@@ -623,24 +623,28 @@
 /styles'));%0A
+    
 %7D);%0A%0Agulp.ta
@@ -715,20 +715,16 @@
 /*.js')%0A
-    
     .pip
@@ -735,20 +735,16 @@
 lify())%0A
-    
     .pip
@@ -767,61 +767,13 @@
 ));%0A
-%7D);%0A%0Agulp.task('default', %5B'minify-css', 'minify-js'%5D
+    %7D
 );%0A%0A
@@ -868,16 +868,20 @@
 load();%0A
+    
 %7D);%0A%0Agul
@@ -911,16 +911,18 @@
 n(cb) %7B%0A
+  
   browse
@@ -929,16 +929,20 @@
 rSync(%7B%0A
+    
     serv
@@ -953,16 +953,22 @@
 %7B%0A      
+     
+ 
 baseDir:
@@ -977,15 +977,23 @@
 ./'%0A
+    
     %7D,%0A
+    
     
@@ -1011,16 +1011,20 @@
 se,%0A    
+ 
+   
 ui: fals
@@ -1030,16 +1030,20 @@
 se,%0A    
+   
+ 
 ghostMod
@@ -1051,23 +1051,27 @@
 : false%0A
+  
   %7D);%0A%0A
+  
   gulp.w
@@ -1157,12 +1157,64 @@
 oad'%5D);%0A%7D);%0A
+%0Agulp.task('default', %5B'minify-css', 'minify-js'%5D);%0A

Clean up gulpfile