llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT--> @llvm/pr-subscribers-lldb Author: None (award999) <details> <summary>Changes</summary> - Allow running when no workspace folder is present, and do not override the `cwd` set in the launch configuration - Support getting configuration from workspace file Issue: #<!-- -->142469 --- Full diff: https://github.com/llvm/llvm-project/pull/142470.diff 1 Files Affected: - (modified) lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts (+2-2) ``````````diff diff --git a/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts b/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts index d61b81e4c041f..b5db45b56d6a6 100644 --- a/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts +++ b/lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts @@ -169,7 +169,7 @@ export async function createDebugAdapterExecutable( workspaceFolder: vscode.WorkspaceFolder | undefined, configuration: vscode.DebugConfiguration, ): Promise<vscode.DebugAdapterExecutable> { - const config = vscode.workspace.getConfiguration("lldb-dap", workspaceFolder); + const config = vscode.workspace.workspaceFile ? vscode.workspace.getConfiguration("lldb-dap") : vscode.workspace.getConfiguration("lldb-dap", workspaceFolder); const log_path = config.get<string>("log-path"); let env: { [key: string]: string } = {}; if (log_path) { @@ -184,7 +184,7 @@ export async function createDebugAdapterExecutable( ...configEnvironment, ...env, }, - cwd: workspaceFolder!!.uri.fsPath, + cwd: configuration.cwd ?? workspaceFolder?.uri.fsPath, }; const dbgArgs = await getDAPArguments(workspaceFolder, configuration); `````````` </details> https://github.com/llvm/llvm-project/pull/142470 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits