How to get browsersync working with jekyll and gulp



Can someone help me out here? I’m at my wit’s end. I’ve installed jekyll, gulp and browsersync, configured gulp (to the best of my ability) and every time I run it I always get a not found error.

This is the gulpfile:

const gulp = require('gulp');
const shell = require('gulp-shell');
const browserSync = require('browser-sync').create();
const siteRoot = "_site/"
// task for building the site when something changed:
gulp.task('serve', shell.task(["bundle exec jekyll serve --host $IP --port $PORT --baseurl ''"]));

// task for serving blog with Browsersync
gulp.task('refresh', function(){
        files: [siteRoot + '**'],
        server: {
            baseDir: siteRoot
        notify: true,
    //Reloads the page when some of the already build files changed:'_site/**/*.*').on('change', browserSync.reload);

gulp.task('default', ['serve', 'refresh']);

I’ve never used these three tools together with cloud9 before…