Removed reference to BrowserSync running instance

master
Shane Osbourne 2014-06-26 08:10:04 +01:00
parent 999c0f4a38
commit 6e0576729a
1 changed files with 2 additions and 3 deletions

View File

@ -27,14 +27,13 @@ var runSequence = require('run-sequence');
var browserSync = require('browser-sync');
var pagespeed = require('psi');
var reload = browserSync.reload;
var bs; // reference to the running instance of browserSync
// Lint JavaScript
gulp.task('jshint', function () {
return gulp.src('app/scripts/**/*.js')
.pipe($.jshint())
.pipe($.jshint.reporter('jshint-stylish'))
.pipe($.if(!bs.active, $.jshint.reporter('fail')))
.pipe($.if(!browserSync.active, $.jshint.reporter('fail')))
.pipe(reload({stream: true}));
});
@ -116,7 +115,7 @@ gulp.task('clean', del.bind(null, ['.tmp', 'dist']));
// Watch Files For Changes & Reload
gulp.task('serve', function () {
bs = browserSync({
browserSync({
notify: false,
server: {
baseDir: ['.tmp', 'app']