Open kristianmandrup opened 7 years ago
This is too many levels deep.
watch: {
prod: {
js: {
Can you prefix your watch tasks with 'prod' or 'dev', then call them like so:
tasks: ['nodemon', 'watch:dev_js', 'watch:dev_sass']
tasks: ['nodemon', 'watch:dev_js', 'watch:dev_sass']
doesn't work, it will only run the first watch task (watch:dev_js in this case)
Hey i had the same issue and did the same logic as you but that didn't work. The working solution and working like a charm is this one: https://stackoverflow.com/questions/13833196/gruntjs-watch-different-folders-and-execute-tasks Hope this helps. you need to install the grunt plugin: https://www.npmjs.com/package/grunt-focus then add like you tried with concurrent: this code
focus: { develop: { include: ['dev'] }, master: { include: ['prod'] }, },
and make ure tasks like this:
grunt.registerTask('dev', 'compile develop', ['focus:develop']); grunt.registerTask('prod', 'compile production', ['focus:master']);
Trying to set up different watch configurations for dev vs prod What am I missing?