Enhancement - runOnStartupOnly
Closed this issue · 4 comments
npm-watch has the neat effect of running scripts in parallel and a runOnStartupOnly option might be useful to tell npm-watch to run a batch of scripts once and then terminate (like npm-run-all).
I am not so sure if this is in scope for this project.
It's point is specifically to provide the ability to watch and re-run scripts.
That said, I will leave this open a bit as I think it over, and to see if anyone else has feedback.
Hello, on my local develop machine "npm run watch" is great. But on server where I do releases, how can i make an command "npm run watch once" or something so it does not keep running in background ?
This hack works for me
"watch": {
"watcher-initialize": {
"patterns": [
"only-run-once.please"
]
}
}
Since there is a workaround, and the feature is out of scope for this project, I am closing the issue.