How can Gulp be restarted upon each Gulpfile change?
You can create a task that will gulp.watch for gulpfile.js and simply spawn another gulp child_process. var gulp = require(‘gulp’), argv = require(‘yargs’).argv, // for args parsing spawn = require(‘child_process’).spawn; gulp.task(‘log’, function() { console.log(‘CSSs has been changed’); }); gulp.task(‘watching-task’, function() { gulp.watch(‘*.css’, [‘log’]); }); gulp.task(‘auto-reload’, function() { var p; gulp.watch(‘gulpfile.js’, spawnChildren); spawnChildren(); function spawnChildren(e) { …