[BUG] Claude Code for VSCode uses powershell.exe instead of pwsh.exe

Resolved 💬 1 comment Opened Apr 28, 2026 by jeffrson Closed Apr 28, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Claude Code for VSCode used a powershell script for some tasks. For whatever reason it used powershell.exe instead of pwsh.exe which obviously has some compatibility issues (utf8NoBOM missing, 3-Argument Join-Path, &&). Also my PROFILE is not read where it initializes node version (by fnm).

update-config does not see any setting to force pwsh.exe. From the documentation it appears pwsh.exe should be autodetected, while powershell.exe is a fallback.

So why doesn't it detect pwsh.exe? Maybe it is because I have a user-only pwsh.exe from Microsoft store.

What Should Happen?

Should detect different pwsh.exe installations - maybe even portable one from PATH.

Error Messages/Logs

Steps to Reproduce

Ask Claude whether it uses Powershell or pwsh - the system prompt in VSCode is said to be powershell.exe

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.121

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗