fix: /ide install failed to run on Windows (#957)

This commit is contained in:
tanzhenxin
2025-11-04 15:53:03 +08:00
committed by GitHub
parent d8cc0a1f04
commit 04f0996327
3 changed files with 12 additions and 14 deletions

View File

@@ -117,15 +117,16 @@ class VsCodeInstaller implements IdeInstaller {
};
}
const isWindows = process.platform === 'win32';
try {
const result = child_process.spawnSync(
commandPath,
isWindows ? `"${commandPath}"` : commandPath,
[
'--install-extension',
'qwenlm.qwen-code-vscode-ide-companion',
'--force',
],
{ stdio: 'pipe' },
{ stdio: 'pipe', shell: isWindows },
);
if (result.status !== 0) {