-
-
Notifications
You must be signed in to change notification settings - Fork 9.2k
Send exit(0) when stdin closed.
#1311
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
Conversation
|
Looks like Appveyor is broken. |
|
@sokra – you mentioned that this feature was PR worthy in #1308, though I'm not sure if it's testable as it's using Totally realize that this is probably an edge-case, but I'm happy to do the work to get it merged in, just need a bit of direction. Thanks! |
|
yeah, there are no automatic tests for the CLI yet. You can goto |
|
So, I'm opening the node process with the ErlangVM and when stdin closes, it's shutting down. Without my patch, the process is never closed. |
|
I just want to know what to do to get this merged |
|
Not sure... I'm not so much into these OS internals to decide if this is fine. Would love to see more feedback about the fix. It's pretty radical and if wrong it would break stuff.. |
|
The same change to brunch broke running it as a background process (brunch/brunch#998). From that discussion, they're going to make this behaviour opt-in through |
|
👍 for this change, it is fairly common behaviour, but I would also follow @jjt advice of only checking stdin if a flag (for example, |
|
I'm just the messenger :) |
|
@matthewlehner Do you want to update the PR to reflect @jjt and @josevalim ideas? And please rebase it to fix the CI bugs. |
|
👍 I'm on it. |
|
@sokra I've just implemented these changes with I've rebased to master, but CI bugs still seem to be here. |
|
The CI build fails because of incorrect code formating. Run |
|
@sokra Ah ha, sorry about that. Everything passes now. 👍 |
|
Just checking if there's anything I can do to help move this along? Appveyor still seems broken for some reason.. |
|
@sokra Just rebased to master and everything passes. Is there anything else I need to do to get this merged? |
Send `exit(0)` when stdin closed.
|
Thanks |
This will send the proper exit signal when stdin closed for #1308
I would like to automatically run
webpack --watchas part of my application but, when it shuts down, the webpack process persists and continues running. I have observed that my application does close STDIN, however,webpack --watchis not currently checking if STDIN was closed or not.