Open
Description
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues.
- Refer to the FAQ.
- Refer to Differences between Windows PowerShell 5.1 and PowerShell.
Steps to reproduce
- Configure OSC 9;9 for PowerShell and add custom prompt in
$PROFILE
following https://learn.microsoft.com/en-us/windows/terminal/tutorials/new-tab-same-directory#powershell-powershellexe-or-pwshexe:
function prompt {
$loc = $executionContext.SessionState.Path.CurrentLocation;
$out = "PS $loc$('>' * ($nestedPromptLevel + 1)) ";
if ($loc.Provider.Name -eq "FileSystem") {
$out += "$([char]27)]9;9;`"$($loc.ProviderPath)`"$([char]27)\"
}
return $out
}
- Type a single quote
'
or a dot.
Expected behavior
PS> '
Actual behavior
PS>\'
Error details
No response
Environment data
PS /home/yen/tmp/PowerShell> $PSVersionTable
Name Value
---- -----
PSVersion 7.4.0-preview.3
PSEdition Core
GitCommitId 7.4.0-preview.3
OS Linux 6.3.8-arch1-1 PowerShell/PowerShell#1 SMP PREEMPT_DYNAMIC Wed, 14 Jun 2023 20:10:31 +0000
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
I can also reproduce the issue with PowerShell 7.3.4 on Windows 10 22H2.
Visuals
This is captured with Konsole 23.04.2 and tmux 3.3a. I can reproduce the same issue with PowerShell 7.3.4 on Windows 10 22H2.