Skip to content

Have lldb-dap extension support multi-root workspace #142470

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 2, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lldb/tools/lldb-dap/src-ts/debug-adapter-factory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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) {
Expand All @@ -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);

Expand Down
Loading