Skip to content

Commit

Permalink
Allow cmake.debugConfig to override the cwd for "run without debuggin…
Browse files Browse the repository at this point in the history
…g" (#1444)
  • Loading branch information
bobbrow authored Sep 21, 2020
1 parent 1797c79 commit 858fb76
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/cmake-tools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1368,9 +1368,10 @@ export class CMakeTools implements vscode.Disposable, api.CMakeToolsAPI {
// a target.
return null;
}
const user_config = this.workspaceContext.config.debugConfig;
const termOptions: vscode.TerminalOptions = {
name: 'CMake/Launch',
cwd: path.dirname(executable.path),
cwd: (user_config && user_config.cwd) || path.dirname(executable.path),
};
if (process.platform == 'win32') {
// Use cmd.exe on Windows
Expand Down

0 comments on commit 858fb76

Please sign in to comment.