From dcc1120f0915d860d9429b4a987f8007f39bead8 Mon Sep 17 00:00:00 2001 From: Victor Costa Date: Wed, 4 May 2016 12:19:35 -0300 Subject: [PATCH] Fix styles watch from gulp --- gulp/watch.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/gulp/watch.js b/gulp/watch.js index 174ed07..c5fbfaa 100644 --- a/gulp/watch.js +++ b/gulp/watch.js @@ -14,10 +14,13 @@ gulp.task('watch', ['inject'], function () { gulp.watch([path.join(conf.paths.src, '/*.html'), 'bower.json'], ['inject-reload']); - gulp.watch([ - path.join(conf.paths.src, '/app/**/*.css'), - path.join(conf.paths.src, '/app/**/*.scss') - ], function(event) { + var stylePaths = []; + conf.paths.allSources.forEach(function(src) { + stylePaths.push(path.join(src, '/app/**/*.css')); + stylePaths.push(path.join(src, '/app/**/*.scss')); + }); + + gulp.watch(stylePaths, function(event) { if(isOnlyChange(event)) { gulp.start('styles-reload'); } else { -- libgit2 0.21.2