You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While CTRL-C interrupts running powershell commands, it does not abort user inputs. For example, if you open Windows PowerShell, type something at command line, and then Ctrl-C, it aborts what you have typed so far, and gives you a new prompt.
We don't do that. We need this feature to interrupt a multi-line command.
Activity
palladia commentedon Mar 2, 2016
On Windows, Ctrl-C is also used to abort user input. This is especially needed for multi-line input, as there' s no other way to abort.
palladia commentedon Mar 2, 2016
I've investigated this a bit, and since current CoreFx does not support Console.TreatCAsInput, this may be hard to implement.
palladia commentedon Mar 2, 2016
Sorry, that was Console.TreatControlCAsInput...
andyleejordan commentedon Mar 2, 2016
What do you mean by interrupt input? We have a handler for Ctrl-C registered in the host to stop a running cmdlet.
palladia commentedon Mar 2, 2016
While CTRL-C interrupts running powershell commands, it does not abort user inputs. For example, if you open Windows PowerShell, type something at command line, and then Ctrl-C, it aborts what you have typed so far, and gives you a new prompt.
We don't do that. We need this feature to interrupt a multi-line command.
andyleejordan commentedon Mar 2, 2016
Could we just do this with our escape mapping? Or in our Ctrl-C handler?
palladia commentedon Mar 2, 2016
Still playing around with it. I think our Ctrl-C handler may be flawed.
vors commentedon Mar 2, 2016
I also complained about the same in #421
I never used
Escfor this and it doesn't work in bash and fish shell.It should be
Ctrl+Cinstead ofEsc.andyleejordan commentedon Mar 2, 2016
Or the
Ctrl-KI have implemented but disabled by request.palladia commentedon Mar 2, 2016
Fixed with #613