Closed xilun closed 7 years ago
The general idea would be to:
We will default to support interactive win32 programs, and maybe add a flag to keep stdin alone (for batch works). IMO this choice is better than adding a flag for interactive usage just to keep Ctrl-Z working by default on e.g. builds. However, if this really breaks Ctrl-Z, some people who might have taken the habit of Ctrl-Z'ing GUI programs, then bg them (because they use to do that under a GNU/Linux system) might be irritated by such breakage. That's one more argument if favor of detection of Win32 GUI programs.
commit ab86dc8
Unfortunately this does not fix all the issues in the AU edition (maybe because of issues in WSL/Console implementation?), but it works quite well in the last Insider build 14946
The wcmd echo.
workaround also is not needed anymore.
However, Ctrl-C while running e.g. wcmd dir /s c:\\
now kills the whole console. I will try to avoid that...
I think there are several steps needed to handle Ctrl-C "properly":
ctrl-c fixed by 771616d closing this ticket to document remaining issues more clearly
(Output breakage is actually also seen in some non-interactive win32 console programs.)
It can probably be fixed in a lot of cases by a few calls of GetConsoleMode() and SetConsoleMode().
In case of concurrent executions there might be no perfect way to do it, but I guess something that works most of the time can be good enough.