@starlens-app/cli 0.1.3 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/index.mjs +8 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@starlens-app/cli",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "description": "Starlens CLI — manage your GitHub starred repositories from the terminal",
5
5
  "type": "module",
6
6
  "bin": {
package/src/index.mjs CHANGED
@@ -717,7 +717,8 @@ function detectProjectRoot() {
717
717
 
718
718
  // Skill 源目录(npm 包内的 skills/ 目录)
719
719
  function getSkillSourceDir() {
720
- return new URL("../../skills/starlens", import.meta.url).pathname;
720
+ // src/index.mjs → ../skills/starlens = cli/skills/starlens
721
+ return new URL("../skills/starlens", import.meta.url).pathname;
721
722
  }
722
723
 
723
724
  // 各客户端全局 skill 目标路径
@@ -1202,7 +1203,8 @@ async function runInstallSkillWizard(args, env) {
1202
1203
  console.log("");
1203
1204
  }
1204
1205
 
1205
- const rl = createReadlineInterface();
1206
+ // rl 在所有 raw-mode 交互结束后再创建,避免 wizardCheckbox 的 \r 泄漏进 readline 缓冲区
1207
+ let rl;
1206
1208
 
1207
1209
  try {
1208
1210
  // Step 1: 多选客户端
@@ -1220,6 +1222,9 @@ async function runInstallSkillWizard(args, env) {
1220
1222
  console.log(`已选择:${clients.map(c => clientLabels[c]).join("、")}`);
1221
1223
  }
1222
1224
 
1225
+ // wizardCheckbox(raw mode)完成后再创建 readline,避免 Enter 残留字符被提前消费
1226
+ rl = createReadlineInterface();
1227
+
1223
1228
  const cwd = process.cwd();
1224
1229
 
1225
1230
  // Step 2: 安装 Skill(默认是)
@@ -1389,7 +1394,7 @@ async function runInstallSkillWizard(args, env) {
1389
1394
  console.log(` 3. 完整文档:${HOSTED_MCP_BASE_URL}/docs/integrations`);
1390
1395
  console.log("");
1391
1396
  } finally {
1392
- rl.close();
1397
+ rl?.close();
1393
1398
  }
1394
1399
  }
1395
1400