From 5cd19894e08985ee87ca5ae06b589be04855308f Mon Sep 17 00:00:00 2001 From: Jarrad Hope Date: Sat, 2 Jul 2016 11:28:09 +0200 Subject: [PATCH] i need to learn gulp --- gulpfile.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 334891e..8c653f7 100755 --- a/gulpfile.js +++ b/gulpfile.js @@ -53,7 +53,6 @@ gulp.task('scripts', function() { gulp.task('watch', ['styles', 'scripts', 'browser-sync'], function() { gulp.watch('src/sass/**/*.+(sass|scss)', ['styles']); gulp.watch('src/*.html', browserSync.reload); - gulp.watch('src/demo/**/*', browserSync.reload); gulp.watch('src/js/**/*.js', browserSync.reload); }); @@ -63,7 +62,6 @@ gulp.task('clean', function() { gulp.task('images', function() { return gulp.src('src/img/**/*') - //.pipe(newer('build/img')) .pipe(plumber()) .pipe(imagemin({ interlaced: true, @@ -74,7 +72,12 @@ gulp.task('images', function() { .pipe(gulp.dest('build/img')); }); -gulp.task('build', ['clean', 'styles', 'scripts', 'images'], function() { +gulp.task('demo', function() { + gulp.src(['src/demo/**/*']) + .pipe(gulp.dest('build/demo')) +}); + +gulp.task('build', ['clean', 'styles', 'scripts', 'images', 'demo'], function() { gulp.src([ 'src/css/main.css'