Skip to content

Commit

Permalink
fix start task
Browse files Browse the repository at this point in the history
  • Loading branch information
eshaibu committed Mar 29, 2017
1 parent df8fc65 commit fce9222
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions gulpfile.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
'use strict';

const gulp = require('gulp');
// const browserSync = require('browser-sync').create();
const browserSync = require('browser-sync');
const nodemon = require('gulp-nodemon');
const sass = require('gulp-sass');
const bower = require('gulp-bower');
Expand All @@ -11,8 +13,8 @@ gulp.task('nodemon', () => {
nodemon({ script: 'server.js' });
});

gulp.task('serve', ['nodemon'], () => {
browserSync.init({
gulp.task('server', ['nodemon'], () => {
browserSync.create({
proxy: "http://localhost:3000",
port: 7000,
files: ["public/**/*.*"],
Expand All @@ -37,10 +39,10 @@ gulp.task('test', () => {
gulp.task('watch', () => {
gulp.watch('public/css/common.scss', ['sass']);
gulp.watch('public/css/*.css');
gulp.watch('public/css/**', browserSync.reload);
gulp.watch('app/views/**', browserSync.reload);
gulp.watch('public/views/**', browserSync.reload);
gulp.watch(['public/js/**', 'app/**/*.js'], browserSync.reload)
gulp.watch('public/css/**', browserSync.create().reload);
gulp.watch('app/views/**', browserSync.create().reload);
gulp.watch('public/views/**', browserSync.create().reload);
gulp.watch(['public/js/**', 'app/**/*.js'], browserSync.create().reload);
livereload.listen();
});

Expand Down

0 comments on commit fce9222

Please sign in to comment.