client/pianoroll/gulp/tasks/watch.js
author rougeronj
Thu, 22 Jan 2015 15:03:58 +0100
changeset 121 df6b39f962bc
parent 84 d7c5bffdd2d8
permissions -rw-r--r--
Add getAnnotCategories to utils and propagate the modification to annotsvizview and annotstimeline

'use strict';

// var config = require('../config.js');
var gulp = require('gulp');
var livereload = require('gulp-livereload');

// Watch
gulp.task('watch', ['connect', 'serve'], function () {
  var server = livereload();
    // Watch for changes in `app` folder
    gulp.watch([
        // 'app/jade/**/*.jade',
        // 'app/*.html',
        // 'app/scss/**/*.scss',
        // 'app/scripts/**/*.js',
        // 'app/images/**/*',
        '.tmp/**/*'
    ]).on('change', function(file) {
      server.changed(file.path);
    });

    // Watch .less files
    gulp.watch('app/less/**/*.less', ['styles']);

    // Watch .js files
    gulp.watch('app/js/**/*.js', ['browserify']);

    // Watch image files
    gulp.watch('app/img/**/*', ['images']);

    // Watch .html files
    gulp.watch('app/**/*.html', ['html']);
});