-
Notifications
You must be signed in to change notification settings - Fork 318
Closed
Labels
Description
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues, especially the pinned issues.
Exception report
N/AScreenshot
Environment data
PS Version: 7.3.7
PS HostName: ConsoleHost
PSReadLine Version: 2.3.3
PSReadLine EditMode: Windows
OS: 10.0.22621.2338 (WinBuild.160101.0800)
BufferWidth: 120
BufferHeight: 9001Steps to reproduce
Run the code snippet in the second example of https://learn.microsoft.com/en-us/powershell/module/psreadline/set-psreadlinekeyhandler?view=powershell-7.3
Set-PSReadLineKeyHandler -Chord Ctrl+B -ScriptBlock {
[Microsoft.PowerShell.PSConsoleReadLine]::RevertLine()
[Microsoft.PowerShell.PSConsoleReadLine]::Insert('build')
[Microsoft.PowerShell.PSConsoleReadLine]::AcceptLine()
}Hit Ctrl+B
Expected behavior
build<enter> should be fed to the prompt
(this is what happens e.g. if -Chord F12 is used)
Actual behavior
^B is displayed
