fix: generalize Windows remote detection for terminal commands#10391
Merged
RomneyDa merged 1 commit intocontinuedev:mainfrom Feb 11, 2026
Merged
Conversation
Broadens the Windows-with-remote check from WSL-only to all non-local remotes (Dev Container, SSH, Codespaces, etc.) so that terminal commands fall back to ide.runCommand() instead of trying to spawn powershell.exe. Fixes continuedev#10007 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
RomneyDa
approved these changes
Feb 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
runTerminalCommand.tsfrom WSL-only (remoteName === "wsl") to all non-local remotes (!["", "local"].includes(remoteName))ide.runCommand()instead of trying to spawnpowershell.exeContext
The
ENABLED_FOR_REMOTESlist already includesdev-container,devcontainer,ssh-remote,attached-container,codespaces, andtunnel— but the guard only excluded WSL from direct exec. Any other remote type on a Windows host would enter the direct spawn path and fail withENOENTbecausepowershell.exeargs target the wrong platform.Fixes #10007
Related: #10067, #9812, #8732
Test plan
🤖 Generated with Claude Code
Summary by cubic
Generalized Windows remote detection in runTerminalCommand to handle all non-local remotes. On Windows with a remote workspace, terminal commands now use ide.runCommand instead of spawning powershell, preventing ENOENT errors across Dev Containers, SSH, Codespaces, etc.
Written for commit b7c2b4f. Summary will update on new commits.