From 46ea8cc436d33e8b61ba78b1b0e930f3b94e4167 Mon Sep 17 00:00:00 2001 From: "bobo.yang" Date: Thu, 6 Jul 2023 09:06:48 +0800 Subject: [PATCH] Fix command execution in checkDevChatDependency function - Enclosed the pipxDevChat command in quotes to ensure correct execution, especially when the path contains spaces. --- src/contributes/commandsBase.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/contributes/commandsBase.ts b/src/contributes/commandsBase.ts index 3dffe10..0bb784e 100644 --- a/src/contributes/commandsBase.ts +++ b/src/contributes/commandsBase.ts @@ -63,7 +63,7 @@ export function checkDevChatDependency(pythonCommand: string): boolean { try { // Check if DevChat is installed const pipxDevChat = path.join(pipxBinPath!, 'devchat'); - runCommand(`${pipxDevChat} --help`); + runCommand(`"${pipxDevChat}" --help`); UiUtilWrapper.updateConfiguration('DevChat', 'DevChatPath', pipxDevChat); const error_status = `DevChat has installed.`;