Powershell does not expand '~' for external programs #20031
Closed
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
PS: ~ > pwsh --version
PowerShell 7.3.6
PS: ~ > cd .config/nvim
PS: .config/nvim > nvim ~/.bashrc # or code ~/.bashrc
- The last command opens an empty
.bashrc
file in current directory in neovim/vscode
Expected behavior
`~` should be expanded to `$HOME`
Actual behavior
pwsh does not expand `~` for external command
Error details
No response
Environment data
Name Value
---- -----
PSVersion 7.3.6
PSEdition Core
GitCommitId 7.3.6
OS Microsoft Windows 10.0.19045
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
Visuals
No response