bundle cli in vscode

This commit is contained in:
tanzhenxin
2025-12-13 20:56:18 +08:00
parent 65796e2799
commit 8e29cc88f9
16 changed files with 369 additions and 1143 deletions

View File

@@ -292,7 +292,14 @@ export async function activate(context: vscode.ExtensionContext) {
}
if (selectedFolder) {
const qwenCmd = 'qwen';
const cliEntry = vscode.Uri.joinPath(
context.extensionUri,
'dist',
'qwen-cli',
'cli.js',
).fsPath;
const quote = (s: string) => `"${s.replaceAll('"', '\\"')}"`;
const qwenCmd = `${quote(process.execPath)} ${quote(cliEntry)}`;
const terminal = vscode.window.createTerminal({
name: `Qwen Code (${selectedFolder.name})`,
cwd: selectedFolder.uri.fsPath,