When using start_process or interact_with_process with PowerShell 7 (pwsh) as the default shell on Windows, the $ character is silently stripped or lost from commands. This makes it impossible to use PowerShell variables like $env:PATH, $PROFILE, $_, etc.
Steps to reproduce:
Set defaultShell to pwsh (PowerShell 7)
Run start_process with a command containing $, e.g.: echo $env:PATH
The $ is stripped — PowerShell receives echo env:PATH instead
Expected behavior: The $ character should be passed through to the shell verbatim.
Actual behavior: The $ is silently removed/eaten, breaking all PowerShell variable references.
Workaround: Write commands to a .ps1 file first, then execute via pwsh -ExecutionPolicy Bypass -File "path.ps1"
Environment:
Windows 11
PowerShell 7 (pwsh)
Desktop Commander (latest via npx)
Claude.ai web interface (Remote MCP)