Merge pull request #1249 from QwenLM/feat/vscode-ide-companion-package-script

fix(vscode-ide-companion): improve cross-platform compatibility in prepackage script
This commit is contained in:
tanzhenxin
2025-12-14 00:02:05 +08:00
committed by GitHub

View File

@@ -35,7 +35,7 @@ function npmBin() {
function run(cmd, args, opts = {}) { function run(cmd, args, opts = {}) {
const res = spawnSync(cmd, args, { const res = spawnSync(cmd, args, {
stdio: 'inherit', stdio: 'inherit',
shell: false, shell: process.platform === 'win32' ? true : false,
...opts, ...opts,
}); });
if (res.error) { if (res.error) {
@@ -71,8 +71,8 @@ function main() {
console.log('[prepackage] Copying bundled CLI dist/ into extension...'); console.log('[prepackage] Copying bundled CLI dist/ into extension...');
run( run(
process.execPath, 'node',
[path.join(extensionRoot, 'scripts', 'copy-bundled-cli.js')], [`${path.join(extensionRoot, 'scripts', 'copy-bundled-cli.js')}`],
{ {
cwd: extensionRoot, cwd: extensionRoot,
}, },