Reputation: 119
Here's my watch.js file :
module.exports = function (grunt) {
grunt.config.set('watch', {
assets: {
// Assets to watch:
files: [
'assets/**/*',
'tasks/pipeline.js',
'!**/node_modules/**',
'!assets/images/**' // <- Added this line to stop watching
],
// When assets are changed:
tasks: [
'syncAssets',
'linkAssets'
]
}
});
I followed this to reduce the folder grunt watches for change but to no avail. Also, I deleted the task folder along with Gruntfile.js file to stop using grunt but doing htop on the server still shows grunt hogging the cpu.
Upvotes: 1
Views: 647
Reputation: 13
Add this in the watch script options : { interval: 1000 }
in Gruntfile.js
Upvotes: 0