docs: fix Zed config schema and add cross-platform ZCODE_BIN paths#7
Conversation
The Zed config example used the obsolete 'acp.agents' schema; the correct current shape is 'agent_servers.<Name>' with type/command/args/env. Also adds a per-platform ZCODE_BIN path table (macOS/Windows/Linux) plus a find-it-yourself fallback, since the CLI is bundled inside the desktop app and not on PATH by default. Mirrors the change in DEVELOPMENT.md.
There was a problem hiding this comment.
Code Review
This pull request updates the documentation (including the English and Chinese READMEs and development docs) to reflect the new custom agent server configuration format (agent_servers) for Zed, replacing the legacy acp configuration. It also documents platform-specific paths for ZCODE_BIN and provides commands to locate the binary. The review feedback correctly identifies that the Windows configuration path should use %LOCALAPPDATA% instead of %APPDATA%, and suggests optimizing the PowerShell search command to target specific subdirectories to avoid performance issues.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| Add the server to Zed as a custom agent server. In `~/.config/zed/settings.json` | ||
| (`%APPDATA%\Zed\settings.json` on Windows): |
There was a problem hiding this comment.
On Windows, Zed stores its global configuration in %LOCALAPPDATA%\Zed\settings.json rather than %APPDATA%\Zed\settings.json (which points to the Roaming directory). Let's update this path to ensure Windows users can find their settings file correctly.
| Add the server to Zed as a custom agent server. In `~/.config/zed/settings.json` | |
| (`%APPDATA%\Zed\settings.json` on Windows): | |
| Add the server to Zed as a custom agent server. In `~/.config/zed/settings.json` | |
| (`%LOCALAPPDATA%\Zed\settings.json` on Windows): |
| > # macOS / Linux | ||
| > find / -name zcode.cjs -path '*resources/glm*' 2>/dev/null | ||
| > # Windows (PowerShell) | ||
| > Get-ChildItem -Path $env:LOCALAPPDATA,$env:APPDATA,'C:\Program Files' -Recurse -Filter zcode.cjs -ErrorAction SilentlyContinue |
There was a problem hiding this comment.
Running Get-ChildItem -Recurse on the entire $env:LOCALAPPDATA and C:\Program Files directories can be extremely slow, potentially taking several minutes and causing high CPU/disk usage. Since ZCode is typically installed in a ZCode subdirectory within these locations, we can restrict the search path to those specific folders to make the command run almost instantly.
| > Get-ChildItem -Path $env:LOCALAPPDATA,$env:APPDATA,'C:\Program Files' -Recurse -Filter zcode.cjs -ErrorAction SilentlyContinue | |
| Get-ChildItem -Path "$env:LOCALAPPDATA\Programs\ZCode", "$env:ProgramFiles\ZCode", "${env:ProgramFiles(x86)}\ZCode" -Recurse -Filter zcode.cjs -ErrorAction SilentlyContinue |
| 将本服务端作为自定义 agent server 添加到 Zed。在 `~/.config/zed/settings.json` | ||
| (Windows 上为 `%APPDATA%\Zed\settings.json`)中: |
There was a problem hiding this comment.
On Windows, Zed stores its global configuration in %LOCALAPPDATA%\Zed\settings.json rather than %APPDATA%\Zed\settings.json (which points to the Roaming directory). Let's update this path to ensure Windows users can find their settings file correctly.
| 将本服务端作为自定义 agent server 添加到 Zed。在 `~/.config/zed/settings.json` | |
| (Windows 上为 `%APPDATA%\Zed\settings.json`)中: | |
| 将本服务端作为自定义 agent server 添加到 Zed。在 `~/.config/zed/settings.json` | |
| (Windows 上为 `%LOCALAPPDATA%\Zed\settings.json`)中: |
| > # macOS / Linux | ||
| > find / -name zcode.cjs -path '*resources/glm*' 2>/dev/null | ||
| > # Windows (PowerShell) | ||
| > Get-ChildItem -Path $env:LOCALAPPDATA,$env:APPDATA,'C:\Program Files' -Recurse -Filter zcode.cjs -ErrorAction SilentlyContinue |
There was a problem hiding this comment.
Running Get-ChildItem -Recurse on the entire $env:LOCALAPPDATA and C:\Program Files directories can be extremely slow, potentially taking several minutes and causing high CPU/disk usage. Since ZCode is typically installed in a ZCode subdirectory within these locations, we can restrict the search path to those specific folders to make the command run almost instantly.
| > Get-ChildItem -Path $env:LOCALAPPDATA,$env:APPDATA,'C:\Program Files' -Recurse -Filter zcode.cjs -ErrorAction SilentlyContinue | |
| Get-ChildItem -Path "$env:LOCALAPPDATA\Programs\ZCode", "$env:ProgramFiles\ZCode", "${env:ProgramFiles(x86)}\ZCode" -Recurse -Filter zcode.cjs -ErrorAction SilentlyContinue |
Summary
Two documentation issues:
1. Wrong Zed config schema
The README examples used the obsolete `acp.agents` shape:
```jsonc
{ "acp": { "agents": [{ "name": "zcode", "command": {...} }] } }
```
The correct current Zed schema is `agent_servers.` with `type`/`command`/`args`/`env`:
```jsonc
{ "agent_servers": { "ZCode": { "type": "custom", "command": "node", "args": [...], "env": {...} } } }
```
2. No cross-platform `ZCODE_BIN` guidance
ZCode's CLI is bundled inside the desktop app and not added to `PATH`. The README only mentioned `ZCODE_BIN` in the env-var table without telling users what path to set — and the path differs per platform.
Adds a per-platform table:
Plus a `find`/`Get-ChildItem` fallback for non-default install locations.
Files
Note on platform paths
If anyone has confirmed the exact Windows/Linux path on their install, please comment and I'll tighten the table.
Verification