diff options
author | Camil Staps | 2015-04-27 17:29:43 +0200 |
---|---|---|
committer | Camil Staps | 2015-04-27 17:29:43 +0200 |
commit | 9ba61ebd7fc87dcaaddcd34dcd7f39e2858cefed (patch) | |
tree | 2a04680018c85765fab64c5f70de0964debb3e68 /gulpfile.js | |
parent | Jade, imagemin, bower dependencies, gulpfile (diff) |
Jade <3, BotleaguesApi.js
Diffstat (limited to 'gulpfile.js')
-rw-r--r-- | gulpfile.js | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/gulpfile.js b/gulpfile.js index b7e9091..2abb17e 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -24,9 +24,17 @@ var gulp = require('gulp'), var bootswatch_theme = 'superhero'; gulp.task('default', [], function() { + gulp.start('styles', 'scripts', 'images', 'jade'); +}); + +gulp.task('all', [], function() { gulp.start('fonts', 'styles', 'scripts', 'images', 'jade'); }); +gulp.task('rebuild', ['clean'], function() { + gulp.start('all'); +}); + gulp.task('clean', function(cb) { del(['./build/assets/css', './build/assets/js', './build/assets/less', './build/assets/img', './build/assets/fonts', './build/*.html'], cb) }); @@ -102,9 +110,8 @@ gulp.task('styles', function() { gulp.task('scripts', function(){ var fileList = [ + './bower_components/jquery/dist/jquery.min.js', './bower_components/bootstrap/dist/js/bootstrap.min.js', - './bower_components/jquery/jquery.min.js', - './src/js/*.js' ]; var dst = './build/assets/js'; @@ -115,6 +122,14 @@ gulp.task('scripts', function(){ .pipe(stripdebug()) .pipe(uglify()) .pipe(gulp.dest(dst)); + + var src = './src/js/*.js'; + + gulp.src(src) + .pipe(changed(dst)) + .pipe(stripdebug()) + .pipe(uglify()) + .pipe(gulp.dest(dst)); }); gulp.task('images', function(){ |