VSCode extension should respect terminal.integrated.cwd for working directory
Resolved 💬 2 comments Opened Feb 10, 2026 by px-anejad Closed Feb 10, 2026
Problem
In a multi-root VSCode workspace, the Claude Code extension always uses the first folder in the folders array as its working directory. It ignores the terminal.integrated.cwd workspace setting.
Context
I have a workspace with multiple project folders:
{
"folders": [
{ "name": "project-a", "path": "project-a" },
{ "name": "project-b", "path": "project-b" },
{ "name": "project-c", "path": "project-c" },
{ "name": "project-d", "path": "project-d" }
],
"settings": {
"terminal.integrated.cwd": "C:\Projects"
}
}
The VS Code integrated terminal correctly starts at C:\Projects (the parent directory), but Claude Code starts at C:\Projects\project-a (the first folder in the list).
Why this matters
- I need Claude Code to operate across multiple repositories under the parent directory, not just the first one listed.
- Adding the parent directory itself as a workspace folder is not desirable because it would include many unrelated directories in the explorer.
- The
terminal.integrated.cwdsetting already expresses the user's intent for terminal working directories — Claude Code should respect it.
Requested behavior
- If
terminal.integrated.cwdis set in the workspace, use that as the Claude Code working directory. - Alternatively, provide a Claude Code-specific setting (e.g.,
claudeCode.workingDirectory) to configure this explicitly.
Environment
- OS: Windows 10
- VSCode multi-root workspace
- Claude Code VSCode extension
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗