-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to configure nodemon.json to run node with arguments which contains space #1823
Comments
This seems to be windows specific (if anyone wants to have a shot) - also it's not clear from original post if this is spaces in nodemon args or nodemon events. Running on mac/linux:
index.js:
nodemon.json: {
"events": {
"exit": "node index.js \"cleanly exited\""
}
} |
@remy But I can execute |
@chucklu remember you're also going through npm |
@remy Do you mean this is a bug of npm? |
Make sure you are not mix-matching single and double quotes, and you don't forget to escape them:
Ran with From your posted config:
It appears you may have forgotten to escape the double quotes surrounding |
@caesay Thanks, I will check it. I did not notice that @remy had already modified the exit script in previous comment. Currently I encounter another issue, which blocked me to confirm the escape double quotes
|
@caesay Still did not work, use the same script as you provided
What I got is as following, still break at the space
|
This issue has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automtically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and @remy will (try!) to follow up. |
The commit that closed this issue (early) adds the fix for windows for this particular issue. The release should auto tag this issue, but if not it'll be in 2.0.12. |
🎉 This issue has been resolved in version 2.0.12 🎉 The release is available on: Your semantic-release bot 📦🚀 |
@remy Thanks for you fix, it works now with the following configuration section in nodemon.config
|
nodemon -v
: 2.0.6node -v
: v12.18.0Configuration in nodemon.json
Expected behaviour
I test the node command
node printdate.js "cleanly exited"
successfully with cmd.exe, and the output isThe parameters were
Actual behaviour
'display at 2021-01-06 17:32:42 408ms UTC+8
The parameter generated by nodemon were
What happened here? why the last parameter was divided into two parts?
Steps to reproduce
The content of printdate.js is as following
The text was updated successfully, but these errors were encountered: