Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ All notable changes to this project are documented in this file.

### Added

- **ZCode 宿主支持**:新增 `zcode` HostAdapter(capabilities: `mcp-stdio` + `skills` + `rules`)。`graphflow install` 现在会检测 `~/.zcode` 并完成三件事:(1) 向 `~/.zcode/cli/config.json` 的 **`mcp.servers`**(ZCode 嵌套结构,新增 `configFormat: "zcode"`)注入 `graphflow` stdio MCP 服务器;(2) 将 `skills/graphflow/SKILL.md` 复制到 `~/.zcode/skills/graphflow/`;(3) 向 `~/.zcode/AGENTS.md` 写入受管指令块(append-with-markers,不动用户内容)。工作区级 `.zcode/config.json` 目标同步支持,`doctor` / `uninstall` 均已覆盖(注入/检测/移除均为幂等操作;卸载时清理 `mcp.servers` 条目但保留其它服务器与顶层键)。新增测试 `tests/m87-zcode-host.test.ts`(3 条:注册表形状 / 安装+状态+幂等 / 预存配置保留)。
- **ZCode 宿主支持**:新增 `zcode` HostAdapter(capabilities: `mcp-stdio` + `skills` + `rules`)。`graphflow install` 现在会检测 `~/.zcode` 并完成三件事:(1) 向 `~/.zcode/cli/config.json` 的 **`mcp.servers`**(ZCode 嵌套结构,新增 `configFormat: "zcode"`)注入 `graphflow` stdio MCP 服务器;(2) 将 `skills/graphflow/SKILL.md` 复制到 `~/.zcode/skills/graphflow/`;(3) 向 `~/.zcode/AGENTS.md` 写入受管指令块(append-with-markers,不动用户内容)。工作区级 `.zcode/config.json` 目标同步支持,`doctor` / `uninstall` 均已覆盖(注入/检测/移除均为幂等操作;卸载时清理 `mcp.servers` 条目但保留其它服务器与顶层键)。新增测试 `tests/m87-zcode-host.test.ts`(3 条:注册表形状 / 安装+状态+幂等 / 预存配置保留)。Windows 上 MCP 命令是 `node.exe` + `npx-cli.js`(与 Codex 相同),m87 不再硬编码 `npx`。

## [1.18.5] - 2026-09-13

Expand Down
20 changes: 14 additions & 6 deletions tests/m87-zcode-host.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,20 @@ describe("M87 ZCode host", () => {
const config = JSON.parse(readFileSync(configPath, "utf8")) as {
mcp?: { servers?: Record<string, { command?: string; args?: string[] }> };
};
expect(config.mcp?.servers?.graphflow?.command).toBe("npx");
expect(config.mcp?.servers?.graphflow?.args).toEqual([
"-y",
"--package=@roarpeng/graphflow",
"graphflow-mcp",
]);
const server = config.mcp?.servers?.graphflow;
expect(server?.command).toBeTruthy();
expect(server?.args).toContain("graphflow-mcp");
expect(server?.args).toContain("--package=@roarpeng/graphflow");
if (process.platform === "win32") {
expect(server?.command?.toLowerCase()).toMatch(/node(\.exe)?$/);
} else {
expect(server?.command).toBe("npx");
expect(server?.args).toEqual([
"-y",
"--package=@roarpeng/graphflow",
"graphflow-mcp",
]);
}

expect(existsSync(join(home, ".zcode", "skills", "graphflow", "SKILL.md"))).toBe(true);
const agents = readFileSync(join(home, ".zcode", "AGENTS.md"), "utf8");
Expand Down