diff --git a/editors/code/package.json b/editors/code/package.json index 34dbea0b2e67..ec325ad3f58c 100644 --- a/editors/code/package.json +++ b/editors/code/package.json @@ -443,11 +443,6 @@ "type": "object", "default": {}, "description": "Optional settings passed to the debug engine. Example:\n{ \"lldb\": { \"terminal\":\"external\"} }" - }, - "rust-analyzer.debug.useLaunchJson": { - "description": "Whether to use existing configurations from launch.json.", - "type": "boolean", - "default": false } } }, diff --git a/editors/code/src/config.ts b/editors/code/src/config.ts index 24002483d441..1652827c32a5 100644 --- a/editors/code/src/config.ts +++ b/editors/code/src/config.ts @@ -116,8 +116,7 @@ export class Config { engine: this.get("debug.engine"), engineSettings: this.get("debug.engineSettings"), openUpDebugPane: this.get("debug.openUpDebugPane"), - sourceFileMap: sourceFileMap, - useLaunchJson: this.get("debug.useLaunchJson"), + sourceFileMap: sourceFileMap }; } } diff --git a/editors/code/src/debug.ts b/editors/code/src/debug.ts index bbf3ff312047..b500fe029a51 100644 --- a/editors/code/src/debug.ts +++ b/editors/code/src/debug.ts @@ -98,18 +98,15 @@ export async function startDebugSession(ctx: Ctx, config: ra.Runnable): Promise< let debugConfig: vscode.DebugConfiguration | undefined = undefined; let message = ""; - if (ctx.config.debug.useLaunchJson) { - const wsLaunchSection = vscode.workspace.getConfiguration("launch"); - const configurations = wsLaunchSection.get("configurations") || []; + const wsLaunchSection = vscode.workspace.getConfiguration("launch"); + const configurations = wsLaunchSection.get("configurations") || []; - const index = configurations.findIndex(c => c.name === config.label); - if (-1 !== index) { - debugConfig = configurations[index]; - message = " (from launch.json)"; - debugOutput.clear(); - } - } - if (!debugConfig) { + const index = configurations.findIndex(c => c.name === config.label); + if (-1 !== index) { + debugConfig = configurations[index]; + message = " (from launch.json)"; + debugOutput.clear(); + } else { debugConfig = await getDebugConfiguration(ctx, config); }