Closed ClemensSchneider closed 7 years ago
same problem, here is my task
gulp.task('pug', function buildHTML() {
return watch('./src/pug/**/*.pug', function () {
gulp.src('./src/pug/*.pug')
.pipe(newer({ dest: './src/', ext: '.html', extra: './src/pug/includes/page-layout.pug'}))
.pipe(pug({
pretty: true
}))
.pipe(gulp.dest('./src'))
.pipe(browserSync.stream());
});
});
Is there a fix to be expected any time soon?
I tried to add gulp-newer to my SCSS task, to only process changed files but to process all files in case one of the settings-files (e.g. _settings.scss) has changed. The extra-parameter looked promising for this but didn't work out as expected. My task is defined as follows:
Before adding the extra-parameter, only the newer files were processed as expected. When changing the settings-files (e.g. _settings.scss), nothing happened. Now, by adding the settings-files as glob via extra-parameter, all files were processed all the time, no matter which file was changed.
Looks like the issue is with the check if bufferedFiles are available:
When using the extra-parameter, bufferedFiles are initialized no matter what and then, if one of the source-files has changed (even if none of the extra-files is newer), all files are passed through...