Skip to content

Commit

Permalink
Integrated fireworm, now it will automatically watch newly created fi…
Browse files Browse the repository at this point in the history
…les.
  • Loading branch information
airportyh committed Aug 22, 2013
1 parent 1292d58 commit 3458c5f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 14 additions & 0 deletions lib/dev_mode_app.js
Expand Up @@ -131,6 +131,10 @@ App.prototype = {
}
var srcFiles = config.get('src_files') || '*.js'
self.watchFiles(srcFiles)
var ignoreFiles = config.get('src_files_ignore')
if (ignoreFiles){
self.ignoreFiles(ignoreFiles)
}
if (cb) cb.call(self)
})
}
Expand All @@ -144,6 +148,16 @@ App.prototype = {
fileWatcher.add(thing)
}
}
, ignoreFiles: function(thing){
var fileWatcher = this.fileWatcher
if (Array.isArray(thing)) {
thing.forEach(function(file){
fileWatcher.ignore(file)
})
} else {
fileWatcher.ignore(thing)
}
}
, onFileRequested: function(filepath){
if (!this.config.get('serve_files')){
this.fileWatcher.add(filepath)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -39,7 +39,7 @@
"growl": "~1.7.0",
"consolidate": "~0.8.0",
"did_it_work": "~0.0.5",
"fireworm": "~0.1.4"
"fireworm": "~0.4.0"
},
"files": [
"lib",
Expand Down

0 comments on commit 3458c5f

Please sign in to comment.