1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-22 17:33:23 +01:00

Use 4.x pattern for watching scss

This commit is contained in:
sdtsui 2017-08-06 13:43:25 -07:00
parent 600f3bfdc9
commit bd9549bddc

View File

@ -148,6 +148,9 @@ gulp.task('copy', gulp.series(gulp.parallel(...copyStrings), 'manifest:productio
gulp.task('copy:watch', function(){
gulp.watch(['./app/{_locales,images}/*', './app/scripts/chromereload.js', './app/*.{html,json}'], gulp.series('copy'))
})
gulp.task('watch:style', function(){
gulp.watch(['ui/app/css/**/*.scss'], gulp.series(['build:scss']))
});
// lint js
@ -191,7 +194,7 @@ gulp.task('build:scss', function () {
});
gulp.task('watch:scss', function () {
return gulp.src('ui/app/css/index.scss')
.pipe(watch('ui/app/css/**/*.scss'))
// .pipe(watch('ui/app/css/**/*.scss'))
.pipe(sourcemaps.init())
.pipe(sass().on('error', sass.logError))
.pipe(sourcemaps.write())
@ -237,7 +240,7 @@ gulp.task('zip', gulp.parallel('zip:chrome', 'zip:firefox', 'zip:edge', 'zip:ope
// high level tasks
gulp.task('dev', gulp.series('build:scss', 'dev:js', 'copy', gulp.parallel('watch:scss', 'copy:watch', 'dev:reload')))
gulp.task('dev', gulp.series('build:scss', 'dev:js', 'copy', gulp.parallel('watch:style', 'copy:watch', 'dev:reload')))
gulp.task('build', gulp.series('clean', 'build:scss', gulp.parallel('build:js', 'copy')))
gulp.task('dist', gulp.series('build', 'zip'))