Skip to content

Instantly share code, notes, and snippets.

@weshardee
Created December 10, 2014 22:05
Show Gist options
  • Save weshardee/e553d8201f4cd11db315 to your computer and use it in GitHub Desktop.
Save weshardee/e553d8201f4cd11db315 to your computer and use it in GitHub Desktop.
grunt task partial for starting a watch task and server in a build folder
/*jshint node:true, laxbreak:true */
'use strict';
module.exports = function(grunt) {
grunt.config.merge({
browserSync: {
bsFiles: {
src: '<%= env.DIR_DEST %>/**/*'
},
options: {
watchTask: true,
server: {
baseDir: '<%= env.DIR_DEST %>'
}
}
}
});
grunt.registerTask('serve', [
'browserSync', 'watch'
]);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment