Skip to content

Instantly share code, notes, and snippets.

View AdamPflug's full-sized avatar

Adam Pflug AdamPflug

View GitHub Profile
@AdamPflug
AdamPflug / watch.jake
Created May 29, 2012 20:47
Jake task to continously monitor the javascript and less files for the project, and rebuild them as necessary
desc('Continously monitors the javascript and less files for the project, and rebuilds them as necessary');
task('watch', ['build'], function () {
// Recursively watch files with a callback
var fs = require('fs');
var files = [];
var findFilesAndWatch = function (path) {
fs.stat(path, function (err, stats) {
if (err) {
return false;