From 5a302f477a924e277ff8e65173a6e346f1580943 Mon Sep 17 00:00:00 2001 From: Carlos Cativo Date: Sat, 11 Apr 2026 06:36:35 -0600 Subject: [PATCH] fix: add Qwen Code dedicated path replacement branches and finishInstall labels (#2082) - Add isQwen branch in copyWithPathReplacement for .md files converting CLAUDE.md to QWEN.md and 'Claude Code' to 'Qwen Code' - Add isQwen branch in copyWithPathReplacement for .js/.cjs files converting .claude paths to .qwen equivalents - Add Qwen Code program and command labels in finishInstall() so the post-install message shows 'Qwen Code' instead of 'Claude Code' Closes #2081 Co-authored-by: Qwen-Coder --- bin/install.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/bin/install.js b/bin/install.js index 50cd93e50..28d59011d 100755 --- a/bin/install.js +++ b/bin/install.js @@ -4149,6 +4149,10 @@ function copyWithPathReplacement(srcDir, destDir, pathPrefix, runtime, isCommand } else if (isCline) { content = convertClaudeToCliineMarkdown(content); fs.writeFileSync(destPath, content); + } else if (isQwen) { + content = content.replace(/CLAUDE\.md/g, 'QWEN.md'); + content = content.replace(/\bClaude Code\b/g, 'Qwen Code'); + fs.writeFileSync(destPath, content); } else { fs.writeFileSync(destPath, content); } @@ -4193,6 +4197,13 @@ function copyWithPathReplacement(srcDir, destDir, pathPrefix, runtime, isCommand jsContent = jsContent.replace(/CLAUDE\.md/g, '.clinerules'); jsContent = jsContent.replace(/\bClaude Code\b/g, 'Cline'); fs.writeFileSync(destPath, jsContent); + } else if (isQwen && (entry.name.endsWith('.cjs') || entry.name.endsWith('.js'))) { + let jsContent = fs.readFileSync(srcPath, 'utf8'); + jsContent = jsContent.replace(/\.claude\/skills\//g, '.qwen/skills/'); + jsContent = jsContent.replace(/\.claude\//g, '.qwen/'); + jsContent = jsContent.replace(/CLAUDE\.md/g, 'QWEN.md'); + jsContent = jsContent.replace(/\bClaude Code\b/g, 'Qwen Code'); + fs.writeFileSync(destPath, jsContent); } else { fs.copyFileSync(srcPath, destPath); } @@ -6261,6 +6272,7 @@ function finishInstall(settingsPath, settings, statuslineCommand, shouldInstallS if (runtime === 'augment') program = 'Augment'; if (runtime === 'trae') program = 'Trae'; if (runtime === 'cline') program = 'Cline'; + if (runtime === 'qwen') program = 'Qwen Code'; let command = '/gsd-new-project'; if (runtime === 'opencode') command = '/gsd-new-project'; @@ -6273,6 +6285,7 @@ function finishInstall(settingsPath, settings, statuslineCommand, shouldInstallS if (runtime === 'augment') command = '/gsd-new-project'; if (runtime === 'trae') command = '/gsd-new-project'; if (runtime === 'cline') command = '/gsd-new-project'; + if (runtime === 'qwen') command = '/gsd-new-project'; console.log(` ${green}Done!${reset} Open a blank directory in ${program} and run ${cyan}${command}${reset}.