/* global module, require */

module.exports = function(gulp, config) {

    'use strict';

    var $ = require('gulp-load-plugins')();
    var browserSync = require('browser-sync');
    var reload = browserSync.reload;
    // var historyApiFallback = require('connect-history-api-fallback');

    // Watch Files For Changes & Reload
    gulp.task('serve', ['jshint', 'styles', 'images', '_translate', '_config'], function() {
        browserSync({
            notify: false,
            logPrefix: 'PSK',
            // Run as an https by uncommenting 'https: true'
            // Note: this uses an unsigned certificate which on first access
            //       will present a certificate warning in the browser.
            // https: true,
            server: {
                baseDir: [config.paths.tmp, config.paths.app],
                // middleware: [historyApiFallback()],
                routes: {
                    '/bower_components': 'bower_components'
                }
            }
        });

        gulp.watch([config.paths.app + '/**/*.html'], reload);
        gulp.watch([config.paths.app + '/**/*.css'], ['styles', reload]);
        gulp.watch([config.paths.app + '/**/*.js'], ['jshint']);
    });

    // Build and serve the output from the dist build
    gulp.task('serve:dist', ['default'], function() {
        browserSync({
            notify: false,
            logPrefix: 'PSK',
            // Run as an https by uncommenting 'https: true'
            // Note: this uses an unsigned certificate which on first access
            //       will present a certificate warning in the browser.
            // https: true,
            server: config.paths.dist
        });
    });
};

@@ -374,18 +374,8 @@
 es',
- 'images',
  '_t
@@ -1196,24 +1196,117 @@
 'jshint'%5D);%0A
+        gulp.watch(%5Bconfig.paths.app + '/resources/config/**/*.json'%5D, %5B'_config', reload%5D);%0A
     %7D);%0A%0A   

Remove image task & Watch config.json in server task