kilo-superpowers-compose 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 (3) hide show
  1. package/README.md +8 -1
  2. package/bin/lib.js +24 -0
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -11,7 +11,7 @@
11
11
 
12
12
  ## Status
13
13
 
14
- **v0.1.3.** Installed via the npm CLI and verified on both **Kilo CLI** and the
14
+ **v0.1.5.** Installed via the npm CLI and verified on both **Kilo CLI** and the
15
15
  **VS Code Kilo Code** extension (they share the same config, so one install
16
16
  covers both).
17
17
 
@@ -89,6 +89,13 @@ Until then, use the npm install above.
89
89
 
90
90
  > v0.1.x 早期版本同时注册了 `/superpowers` 斜杠命令;自 v0.1.3 起移除以与
91
91
  > mimo-compose 保持一致——选 `compose` 代理即可触发完整工作流,不再占用命令面板。
92
+ > **从老版本升级到 v0.1.3+:** 若你的 `~/.config/kilo/commands/superpowers.md`
93
+ > 仍是 v0.1.2 之前留下的副本,运行 `kilo-superpowers-compose uninstall`(再 install
94
+ > 也可)会顺手清掉它。如果还想自己手动清:
95
+ >
96
+ > ```powershell
97
+ > Remove-Item -Force "$env:USERPROFILE\.config\kilo\commands\superpowers.md"
98
+ > ```
92
99
 
93
100
  ## Update & uninstall
94
101
 
package/bin/lib.js CHANGED
@@ -259,6 +259,16 @@ export function runInstall(opts = {}) {
259
259
  }
260
260
  }
261
261
 
262
+ // 1.5 兜底清理:v0.1.3 之前的版本曾向 ~/.config/kilo/commands/superpowers.md
263
+ // 写入 /superpowers 斜杠命令副本(已随 v0.1.3 停止分发)。老用户机器上若
264
+ // 残留该文件,install / update 路径上都主动删掉它,消除 Kilo 命令面板里的
265
+ // 幽灵条目。该清理与 uninstall 路径共用的 safeRemove 幂等安全。
266
+ const legacyCmdInInstall = path.join(ctx.configDir, 'commands', 'superpowers.md');
267
+ let legacyRemovedOnInstall = false;
268
+ if (linkExists(legacyCmdInInstall)) {
269
+ legacyRemovedOnInstall = safeRemove(legacyCmdInInstall, { dryRun, log });
270
+ }
271
+
262
272
  // 2. 备份 kilo.jsonc
263
273
  const bak = backupConfig(ctx.configFile, { dryRun, log });
264
274
 
@@ -344,6 +354,9 @@ export function runInstall(opts = {}) {
344
354
  }
345
355
  console.log(` 代理: ${agentFiles.map((f) => f.name).join(', ') || '(无)'}`);
346
356
  console.log(` kilo.jsonc: skills.paths ${added ? '已新增条目' : '已存在(幂等跳过)'}`);
357
+ if (legacyRemovedOnInstall) {
358
+ console.log(` 遗留命令: 已移除 ~/.config/kilo/commands/superpowers.md(来自 v0.1.3 之前版本)`);
359
+ }
347
360
  console.log('');
348
361
  console.log(' 请重启 Kilo CLI / VS Code 扩展以加载。');
349
362
  console.log('');
@@ -386,6 +399,14 @@ export function runUninstall(opts = {}) {
386
399
  }
387
400
  for (const p of agentPaths) safeRemove(p, { dryRun, log });
388
401
 
402
+ // 1b. 兜底清理:从 v0.1.3 之前的版本残留的 /superpowers 斜杠命令副本。
403
+ // 新安装已不再分发该命令;但老用户机器上可能还留有旧文件,主动清掉防止幽灵命令。
404
+ const legacyCmd = path.join(ctx.configDir, 'commands', 'superpowers.md');
405
+ let legacyRemoved = false;
406
+ if (linkExists(legacyCmd)) {
407
+ legacyRemoved = safeRemove(legacyCmd, { dryRun, log });
408
+ }
409
+
389
410
  // 2. 移除技能链接(清单有记录类型则用之,否则按链接处理)
390
411
  if (linkExists(ctx.skillLink)) {
391
412
  safeRemove(ctx.skillLink, { dryRun, log });
@@ -430,6 +451,9 @@ export function runUninstall(opts = {}) {
430
451
  console.log(` agents: ${agentPaths.length} 个文件`);
431
452
  console.log(` 技能链接: ${ctx.skillLink}`);
432
453
  console.log(` kilo.jsonc: skills.paths 移除 ${removedEntries} 条`);
454
+ if (legacyRemoved) {
455
+ console.log(` 遗留命令: 已移除 ~/.config/kilo/commands/superpowers.md(来自 v0.1.3 之前版本)`);
456
+ }
433
457
  console.log(' 未触碰用户自有的技能 / 代理 / 配置。');
434
458
  return EXIT.OK;
435
459
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kilo-superpowers-compose",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "description": "将 obra/superpowers 工作流打包为 Kilo 插件:一个 compose 编排器代理、3 个子代理与 14 个技能,通过 compose 代理选择器直接进入完整工作流,一条命令安装。",
5
5
  "keywords": [
6
6
  "kilo",