var gulp =require('gulp');
var browserSync = require('browser-sync').create();
var jade = require('gulp-jade');
var path = {
jade: 'app/jade/**/*.jade',
html: 'app/*.html'
};
gulp.task('jade', function(){
return gulp.src('app/jade/*.jade')
.pipe(jade({
pretty: true
}))
.pipe(gulp.dest('app'));
});
gulp.task('watch', function() {
gulp.watch(path.html).on('change', browserSync.reload);
gulp.watch(path.jade, ['jade']);
});
gulp.task('default', ['watch'], function() {
browserSync.init({
notify: false,
server: {
baseDir: ['.tmp','app']
}
});
});