Prerequisites
Steps to reproduce
To recap the repro steps: The problem occurs:
- on Windows
- in regular console windows (
conhost.exe), not in Windows Terminal
- with the
VirtualTerminalLevel registry value in key HKEY_CURRENT_USER\Console NOT manually set to 1, i.e. either set to 0 or - as is the default - with the value not defined.
- with input from external programs
# From a conhost.exe console window on Windows,
# with the defaults (see note re `VirtualTerminalLevel` above).
cmd /c echo foo | Select-String f
Suboptimal workarounds:
- Enclose the external-program call in
(...)
- Enable ANSI/VT support in
conhost.exe console windows system-wide, via the registry:
Suspected cause, quoting @SeeminglyScience from #18294 (comment):
I would guess it's related to #16612 but I've looked it over and I can't easily see how. We should be re-enabling VT more often rather than less, so something is a little off for sure. /cc @daxian-dbw
Expected behavior
with f inverted, to highlight the matching part of the line.
Actual behavior
That is, the VT escape sequence weren't rendered.
Error details
No response
Environment data
PowerShell 7.4.0 on Windows 11 22H2
Visuals
No response
Prerequisites
Steps to reproduce
Resolution-External.To recap the repro steps: The problem occurs:
conhost.exe), not in Windows TerminalVirtualTerminalLevelregistry value in keyHKEY_CURRENT_USER\ConsoleNOT manually set to1, i.e. either set to0or - as is the default - with the value not defined.Suboptimal workarounds:
(...)conhost.execonsole windows system-wide, via the registry:Set-ItemProperty HKCU:\Console VirtualTerminalLevel -Type DWORD 1conhost.execonsole windows on Windows #19101 (comment)Suspected cause, quoting @SeeminglyScience from #18294 (comment):
Expected behavior
foowith
finverted, to highlight the matching part of the line.Actual behavior
←[7mf←[0mooThat is, the VT escape sequence weren't rendered.
Error details
No response
Environment data
Visuals
No response