@lmzhen/dsh-evolution-commands 0.27.3 → 0.29.0

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.
package/lib/index.js CHANGED
@@ -30,6 +30,7 @@ const COMMAND_FALLBACKS = {
30
30
  approval: { command: "/evolution pending … /evolution approve <id> … /evolution reject <id> … /evolution release <id>" },
31
31
  "skill-history": { command: "/evolution restore <name> [v](查看:/evolution skills history <name>)" },
32
32
  "skill-health": { command: "/evolution skills refresh(健康行:/evolution doctor)" },
33
+ merge: { command: "/evolution merge status / pending / approve <id> / report" },
33
34
  diagnostics: {
34
35
  command: "/evolution doctor",
35
36
  platformCli: "dsh --json /evolution doctor"
@@ -1892,6 +1893,11 @@ function entryFlags(entry) {
1892
1893
  return found;
1893
1894
  }
1894
1895
  const COMMAND_ENTRIES = [
1896
+ {
1897
+ readonly: false,
1898
+ usage: "merge <subcommand> [<args>]",
1899
+ summary: "技能自动合并(扫描/待批准/重跑/报告/撤销)"
1900
+ },
1895
1901
  {
1896
1902
  readonly: true,
1897
1903
  usage: "pending [--detail]",
@@ -2400,6 +2406,12 @@ function apply(ctx, rawConfig = {}) {
2400
2406
  kind: "error",
2401
2407
  text
2402
2408
  });
2409
+ if (input === "merge" || input.startsWith("merge ")) {
2410
+ const merge = ctx.get("evolutionMerge");
2411
+ if (merge === void 0) return err("merge 未挂载:当前安装形态没有 evolution-merge 行(安装形态与命令可用性见 INSTALL.md),或先运行 /evolution doctor。");
2412
+ const result = await merge.run(rawInputTrimmed, { agent: invocation.agent });
2413
+ return result.ok ? ok(result.text) : err(result.text);
2414
+ }
2403
2415
  const invocationAgent = invocation.agent;
2404
2416
  const agentMissing = (need) => invocationAgent === void 0 ? err(errorText("e-305-this-invocation-carries-no", { a1: need })) : void 0;
2405
2417
  const unreplayableWriteRefusal = (what) => {
@@ -16,7 +16,7 @@ export interface CommandFallbackHint {
16
16
  readonly platformCli?: string;
17
17
  }
18
18
  /** The four Host surfaces (keyed exactly like the frozen `COMMAND_FALLBACK_SURFACES`). */
19
- export type CommandFallbackSurface = 'approval' | 'skill-history' | 'skill-health' | 'diagnostics';
19
+ export type CommandFallbackSurface = 'approval' | 'skill-history' | 'skill-health' | 'merge' | 'diagnostics';
20
20
  /**
21
21
  * One entry per Host surface. The command column names the same service methods the routes call,
22
22
  * so the answers (and refusal sentences) match the panel.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@lmzhen/dsh-evolution-commands",
3
3
  "description": "Human commands for the evolution family (/evolution pending|curator|maintain|doctor) (community build)",
4
- "version": "0.27.3",
4
+ "version": "0.29.0",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -27,12 +27,12 @@
27
27
  "license": "MIT",
28
28
  "dependencies": {
29
29
  "@deepseek-ai/schemastery": "^3.18.5",
30
- "@lmzhen/dsh-evolution-approval": "^0.27.3",
31
- "@lmzhen/dsh-evolution-core": "^0.27.3",
32
- "@lmzhen/dsh-evolution-maintenance": "^0.27.3"
30
+ "@lmzhen/dsh-evolution-approval": "^0.29.0",
31
+ "@lmzhen/dsh-evolution-core": "^0.29.0",
32
+ "@lmzhen/dsh-evolution-maintenance": "^0.29.0"
33
33
  },
34
34
  "optionalDependencies": {
35
- "@lmzhen/dsh-evolution-agent-preset": "^0.27.3"
35
+ "@lmzhen/dsh-evolution-agent-preset": "^0.29.0"
36
36
  },
37
37
  "peerDependencies": {
38
38
  "@deepseek-ai/cordis": "^4.0.5",