Skip to content

Commit

Permalink
Upgrade gulp to get the gulpfile to work.
Browse files Browse the repository at this point in the history
  • Loading branch information
beger committed Nov 5, 2019
1 parent 8b31a98 commit 1e055c5
Show file tree
Hide file tree
Showing 3 changed files with 5,066 additions and 3,176 deletions.
28 changes: 14 additions & 14 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,9 @@ gulp.task('jekyll-build', function (done) {
/**
* Rebuild Jekyll & do page reload
*/
gulp.task('jekyll-rebuild', ['jekyll-build'], function () {
gulp.task('jekyll-rebuild', gulp.series('jekyll-build', function () {
browserSync.reload();
});

/**
* Wait for jekyll-build, then launch the Server
*/
gulp.task('browser-sync', ['sass', 'jekyll-build'], function() {
browserSync({
server: {
baseDir: '_site'
}
});
});
}));

/**
* Compile files from _scss into both _site/css (for live injecting) and site (for future jekyll builds)
Expand All @@ -53,6 +42,17 @@ gulp.task('sass', function () {
.pipe(gulp.dest('assets/css'));
});

/**
* Wait for jekyll-build, then launch the Server
*/
gulp.task('browser-sync', gulp.series('sass', 'jekyll-build', function() {
browserSync({
server: {
baseDir: '_site'
}
});
}));

/**
* Watch scss files for changes & recompile
* Watch html/md files, run jekyll & reload BrowserSync
Expand All @@ -66,4 +66,4 @@ gulp.task('watch', function () {
* Default task, running just `gulp` will compile the sass,
* compile the jekyll site, launch BrowserSync & watch files.
*/
gulp.task('default', ['browser-sync', 'watch']);
gulp.task('default', gulp.series('browser-sync', 'watch'));
Loading

0 comments on commit 1e055c5

Please sign in to comment.