From 76a707e5bfaa8f65e6c0eba8b0e972d655d6d8f1 Mon Sep 17 00:00:00 2001 From: Pablo Vazquez Date: Tue, 20 Nov 2018 19:19:22 +0100 Subject: [PATCH] Gulp: Watch for changes in both blender-cloud and pillar folders. --- gulpfile.js | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 3cf5106..0b53d7f 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -94,10 +94,24 @@ gulp.task('watch',function() { livereload.listen(); } - gulp.watch('src/styles/**/*.sass',['styles']); - gulp.watch(source.pillar + 'src/styles/**/*.sass',['styles']); - gulp.watch('src/scripts/*.js',['scripts']); - gulp.watch('src/templates/**/*.pug',['templates']); + let watchStyles = [ + 'src/styles/**/*.sass', + source.pillar + 'src/styles/**/*.sass', + ]; + + let watchScripts = [ + 'src/scripts/**/*.js', + source.pillar + 'src/scripts/**/*.js', + ]; + + let watchTemplates = [ + 'src/templates/**/*.pug', + source.pillar + 'src/templates/**/*.pug', + ]; + + gulp.watch(watchStyles,['styles']); + gulp.watch(watchScripts,['scripts']); + gulp.watch(watchTemplates,['templates']); });