diff options
author | vsrs <[email protected]> | 2020-05-07 15:07:58 +0100 |
---|---|---|
committer | vsrs <[email protected]> | 2020-05-07 15:07:58 +0100 |
commit | 5426e2927e317a5e78179a5bd74b9414c0651b86 (patch) | |
tree | 0f8d8b987f6e3c5765cfbad5c66791954893a1c2 /editors/code/src/commands | |
parent | c4ca6e29c25df209c2733ef24b8b4eca70ee93a4 (diff) |
Add additional debug options
Diffstat (limited to 'editors/code/src/commands')
-rw-r--r-- | editors/code/src/commands/runnables.ts | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/editors/code/src/commands/runnables.ts b/editors/code/src/commands/runnables.ts index 7bb8727e7..782a7ba89 100644 --- a/editors/code/src/commands/runnables.ts +++ b/editors/code/src/commands/runnables.ts | |||
@@ -91,8 +91,6 @@ function getCppvsDebugConfig(config: ra.Runnable, executable: string, sourceFile | |||
91 | const debugOutput = vscode.window.createOutputChannel("Debug"); | 91 | const debugOutput = vscode.window.createOutputChannel("Debug"); |
92 | 92 | ||
93 | async function getDebugExecutable(config: ra.Runnable): Promise<string> { | 93 | async function getDebugExecutable(config: ra.Runnable): Promise<string> { |
94 | debugOutput.clear(); | ||
95 | |||
96 | const cargo = new Cargo(config.cwd || '.', debugOutput); | 94 | const cargo = new Cargo(config.cwd || '.', debugOutput); |
97 | const executable = await cargo.executableFromArgs(config.args); | 95 | const executable = await cargo.executableFromArgs(config.args); |
98 | 96 | ||
@@ -130,8 +128,16 @@ export function debugSingle(ctx: Ctx): Cmd { | |||
130 | return; | 128 | return; |
131 | } | 129 | } |
132 | 130 | ||
131 | debugOutput.clear(); | ||
132 | if (ctx.config.debug.openUpDebugPane) { | ||
133 | debugOutput.show(true); | ||
134 | } | ||
135 | |||
133 | const executable = await getDebugExecutable(config); | 136 | const executable = await getDebugExecutable(config); |
134 | const debugConfig = knownEngines[debugEngine.id](config, executable, debugOptions.sourceFileMap); | 137 | let debugConfig = knownEngines[debugEngine.id](config, executable, debugOptions.sourceFileMap); |
138 | for (var key in debugOptions.engineSettings) { | ||
139 | debugConfig[key] = (debugOptions.engineSettings as any)[key]; | ||
140 | } | ||
135 | 141 | ||
136 | debugOutput.appendLine("Launching debug configuration:"); | 142 | debugOutput.appendLine("Launching debug configuration:"); |
137 | debugOutput.appendLine(JSON.stringify(debugConfig, null, 2)); | 143 | debugOutput.appendLine(JSON.stringify(debugConfig, null, 2)); |