Add event example

This commit is contained in:
Kyle Robinson Young 2013-02-25 10:04:52 -08:00
parent 8006886e52
commit e09316644c

View File

@ -33,6 +33,22 @@ grunt.initConfig({
});
```
```js
// Example using watch events
grunt.initConfig({
watch: {
scripts: {
files: ['lib/*.js']
}
}
});
// Listen for events when files are modified
grunt.event.on('watch', function(action, filepath) {
grunt.log.writeln(filepath + ' has ' + action);
});
```
# FAQs
## How do I fix the error `EMFILE: Too many opened files.`?