Skip to content

Commit

Permalink
Put only a command to run as a first argument in spawn method
Browse files Browse the repository at this point in the history
  • Loading branch information
ono-max authored and mame committed Jan 4, 2023
1 parent 1b9b6d9 commit e4859d3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion vscode/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ function executeTypeProf(folder: vscode.WorkspaceFolder, arg: String): child_pro
typeprof = child_process.spawn(process.env.SYSTEMROOT + "\\System32\\cmd.exe", ["/c", cmd], { cwd });
}
else {
typeprof = child_process.spawn(cmd, { cwd });
const cmds = cmd.split(' ')
typeprof = child_process.spawn(cmds[0], cmds.slice(1), { cwd });
}

return typeprof;
Expand Down

0 comments on commit e4859d3

Please sign in to comment.