Currently, editing and selecting text, like expressions or file paths, in the PowerShell REPL is quite cumbersome because only letters (Regex \w character group) are considered word boundaries.
I would expect the cursor to stop at the next non-letter (Regex \W character group) character when navigating using CTRL + LEFT/RIGHT ARROW.
Prerequisites
Screenshot

Environment data
PS Version: 7.5.4
PS HostName: ConsoleHost
PSReadLine Version: 2.3.6
PSReadLine EditMode: Windows
OS: 10.0.19041.4406 (WinBuild.160101.0800)
BufferWidth: 120
BufferHeight: 9001
Steps to reproduce
- Enter a text like the one from the screenshot into a PowerShell window:
Out-File '.\Temp\Test.csv'
- Move the cursor using CTRL + LEFT/RIGHT ARROW keys
Expected behavior
Pressing CTRL + SHIFT + LEFT/RIGHT ARROW keys, I'd expect text selection to switch from Temp... to \Temp..., then .\Temp..., '.\Temp..., File '.\Temp... etc.
Actual behavior
Pressing CTRL + SHIFT + LEFT/RIGHT ARROW keys, text selection switches from Temp... to File '.\Temp... etc.
Currently, editing and selecting text, like expressions or file paths, in the PowerShell REPL is quite cumbersome because only letters (Regex
\wcharacter group) are considered word boundaries.I would expect the cursor to stop at the next non-letter (Regex
\Wcharacter group) character when navigating using CTRL + LEFT/RIGHT ARROW.Prerequisites
Screenshot
Environment data
Steps to reproduce
Out-File '.\Temp\Test.csv'Expected behavior
Pressing CTRL + SHIFT + LEFT/RIGHT ARROW keys, I'd expect text selection to switch from Temp... to \Temp..., then .\Temp..., '.\Temp..., File '.\Temp... etc.
Actual behavior
Pressing CTRL + SHIFT + LEFT/RIGHT ARROW keys, text selection switches from Temp... to File '.\Temp... etc.