Skip to content

Commit 135dddd

Browse files
committed
Fix argument handling in sketch run command to support extra arguments
1 parent fcc8f3b commit 135dddd

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

client/src/setupConsole.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,14 @@ export default function setupConsole(context: ExtensionContext) {
3232
commands.executeCommand('processingConsoleView.focus');
3333
commands.executeCommand('processing.sketch.stop');
3434

35+
const extraArgs = [];
36+
if (Array.isArray(extraArguments)) {
37+
extraArgs.push(...extraArguments);
38+
}
39+
3540
const proc = spawn(
3641
state.selectedVersion.path,
37-
['cli', `--sketch=${dirname(resource.fsPath)}`, ...extraArguments, '--run'],
42+
['cli', `--sketch=${dirname(resource.fsPath)}`, ...extraArgs, '--run'],
3843
{
3944
shell: false,
4045
}

0 commit comments

Comments
 (0)