We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 32f2432 commit bb04ddeCopy full SHA for bb04dde
src/services/mcp/McpHub.ts
@@ -270,8 +270,11 @@ export class McpHub {
270
private getDefaultCwd() {
271
const paths = vscode.workspace.workspaceFolders
272
if (paths?.length === 1) {
273
+ // In workspaces with a single folder, we can safely use it as the default CWD for MCP servers
274
return paths[0].uri.fsPath
275
}
276
+ // Otherwise we return undefined, which means the MCP process will be spawned with
277
+ // NodeJS default CWD, i.e. process.cwd()
278
return undefined
279
280
0 commit comments