Skip to content

feat(clients): register Qoder CLI during setup - #1572

Merged
morluto merged 4 commits into
morluto:mainfrom
IvenKooLab:feat/qoder-client
Oct 12, 2026
Merged

morluto merged 4 commits into
morluto:mainfrom
IvenKooLab:feat/qoder-client

Conversation

@IvenKooLab

Copy link
Copy Markdown
Contributor

Summary

Registers the Qoder CLI as a supported client during npx rea-agents setup, following the same pattern as the merged Qwen Code registration (#1415). After this change, Qoder users can install REA with one command: setup writes the rea MCP server into the user-level ~/.qoder/settings.json.

Problem and expected behavior

Qoder (Alibaba's agentic coding IDE/CLI) is not among the clients setup recognizes, so its users must hand-edit their settings to add REA's MCP server. Expected behavior: after setup, mcpServers.rea exists in ~/.qoder/settings.json; uninstall removes exactly the rea entry.

Qoder's configuration (per the official CLI MCP reference):

  • MCP servers are configured under the top-level mcpServers field of the user-scope ~/.qoder/settings.json.
  • Entries carry command, args, env (and optional cwd); stdio is the default transport when type is omitted.
  • The user location honors the QODER_CONFIG_DIR override (matched the same way as CODEX_HOME).
  • Qoder installs Skills through its Extensions UI rather than a documented personal skills directory, so this definition has no skillPath and setup skips the skill copy.

Change and scope

  • SupportedClients: qoder definition — config path ~/.qoder/settings.json, marker ~/.qoder, format json (the standard mcpServers dialect), QODER_CONFIG_DIR override honored.
  • No dialect changes: mcpServers with command/args/env is exactly the existing json format.
  • Skill install/uninstall flows already skip definitions without skillPath, so no SetupPlan/Uninstall changes are needed.
  • Intentionally out of scope: the Qoder IDE variant. Its MCP file location is not officially documented (community reports point at IDE-managed caches like SharedClientCache/mcp.json), so this PR targets the officially documented CLI settings file, which lives in the same ~/.qoder root.

Contract and boundary impact

  • Semantic owner and earliest changed stage: application-layer setup client registration (SupportedClients).
  • CLI and MCP/tool-catalog contract: none (no tools added or changed).
  • Provider, bridge, target-format, or platform compatibility: adds the qoder client reusing the existing json configuration format.
  • Evidence, artifact, provenance, or reconstruction contract: not applicable.
  • Process execution, authorization, cleanup, or containment impact: uninstall removes only the rea entry.
  • Generated metadata (docs/public/product-catalog.json), package, or installation impact: none authored; generated catalogs stay CI-owned.

Evidence and regression coverage

  • Tests added or updated: tests/boundary/filesystem/qoderClientConfiguration.test.ts (6 cases) — config path resolution across platforms, QODER_CONFIG_DIR override (set and empty), upsert preserving unrelated mcpServers entries and settings keys, fresh/empty documents, and uninstall removing only rea. clientLifecycle.test.ts expected-client list now includes qoder.
  • Base reproduction or other evidence: not applicable (feature).
  • User-visible CLI/MCP output (if applicable): setup and uninstall now list "Qoder" as a client label.
  • Remaining proof gaps: the full boundary suite was not run on a Unix host locally; two pre-existing symlink tests in clientLifecycle.test.ts fail on this Windows machine because Node cannot create symlinks without Developer Mode, reproduced identically on stock main.

For evidence-bearing changes:

  • Observed, derived, and inferred claims remain distinguishable.
  • Artifact identity, source provenance, and failed attempts remain preserved.
  • Unsupported, incomplete, unavailable, or uncertain outcomes remain visible.

Validation performed

  • npm ci — clean install (Node v22.23.2, npm 10.9.8; .nvmrc pins 24.18.0, so CI covers the pinned toolchain)
  • npx vitest run tests/boundary/filesystem/qoderClientConfiguration.test.ts — 6/6 passed
  • npx tsc -p tsconfig.json --noEmit — clean
  • npm run check:fast — typecheck + lint green (also runs as the pre-push hook)
  • npm run verify:test-discovery — all test files discovered exactly once
  • npx vitest run tests/boundary/filesystem/clientLifecycle.test.ts — 41/43 passed; the 2 failures are the pre-existing Windows symlink cases described above (identical on main)

Compatibility, safety, and release

  • Breaking changes or migration steps: none.
  • Real Hopper/Ghidra, browser, or OS coverage: not applicable; config I/O is covered by filesystem boundary tests.
  • Package or release metadata impact: none.
  • Security, privacy, process, or containment review: setup writes only the rea entry into ~/.qoder/settings.json (preserving all unrelated settings); no network access or process execution added.

Review checklist

  • This PR addresses a concrete problem or an agreed enhancement.
  • The PR has one focused outcome and the title follows type(scope): outcome.
  • Related issue is linked, or the reason for not linking one is stated above. (No open issue for Qoder support found; same-pattern precedent in feat(clients): register Qwen Code during setup #1415.)
  • Tests cover changed observable behavior and meaningful failure paths.
  • Owning docs, contracts, and generated metadata are updated where needed.
  • User-visible CLI/MCP changes include representative output. (New client label in the setup client list only.)
  • I checked the final diff for secrets, unrelated cleanup, and unsupported claims.

- SupportedClients: qoder definition (~/.qoder/settings.json, format
  json, QODER_CONFIG_DIR override honored)
- Qoder CLI documents mcpServers as the user-scope server table with
  command/args/env and stdio as the default transport; no personal
  skills directory is documented, so setup skips the skill copy
- tests: qoderClientConfiguration.test.ts (path resolution and
  QODER_CONFIG_DIR override, upsert preserving unrelated settings,
  fresh/empty configs, uninstall)

Verified: tsc --noEmit clean; vitest run
tests/boundary/filesystem/qoderClientConfiguration.test.ts 6/6.
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@CassieFox23

Copy link
Copy Markdown
Contributor

TL;DR: Setup writes the right config file for this closed-source terminal coding agent. Tests pass on Node 22, 24 and 26. The new docs text says setup makes no skill copy, but it still copies one to ~/.agents/skills, while the agent's docs list ~/.qoder/skills.

Results

Tested on Linux. The PR is bd56fe2e9. Main is 6d8f95e38.

Check Result
~/.qoder/settings.json, mcpServers key and QODER_CONFIG_DIR against the MCP reference and settings reference match
Skill: the definition has no skillPath setup falls back to the shared ~/.agents/skills copy. The new docs text says no copy is made. The skills page lists ~/.qoder/skills/<name>/SKILL.md
Changed tests (49), Node 22.23.1, 24.18.0, 26.11.1 49 of 49 on each
npm run build, npm run docs:check (Node 24) exit 0, exit 0
Fresh home: setup, doctor, setup again, uninstall all work. The second setup changes nothing. Uninstall removes the entry and the skill
Existing config with theme, permissions and another server all kept after setup and after uninstall
Bad JSON refused, nothing written
Merge with main clean. It conflicts with #1564 in three files and with #1573 in docs/installation.md

The shared copy is how setup treats any client without a skillPath. Qwen Code did the same in my earlier test. So the code does what the PR intends. The sentence in docs/installation.md is what is off. The PR also says the agent has no personal skills folder, and its docs list one. A skillPath of ~/.qoder/skills would follow the docs.

Not run

  • The agent itself is not installed, so I did not check that it loads the entry.
  • I did not test whether it reads ~/.agents/skills.
  • I did not run Windows or macOS, lint, verify:package or the full suite.

Thanks, IvenKooLab, for the tests of the QODER_CONFIG_DIR override, set and empty.

Cases I ran and what they showed
Case Result
Fresh home creates ~/.qoder/settings.json; doctor says aligned
QODER_CONFIG_DIR=$H/qcfg setup edits qcfg/settings.json and leaves ~/.qoder/settings.json alone. The skill still goes to ~/.agents/skills
QODER_CONFIG_DIR= (empty) uses ~/.qoder
QODER_CONFIG_DIR=rel/qoder setup writes under the current folder. The docs do not say how a relative value is read
A skill already in ~/.qoder/skills left alone
Empty file setup fills it in

Uninstall leaves an empty mcpServers table and a .rea.backup file. I saw the same leftovers for Qwen Code in an earlier test, so this is not new.

Comments in the settings file

The settings page says the file allows // comments. Setup took a commented file. Both setup and uninstall kept every comment.

Open source check

I found no source repository for the CLI. Its npm package has no licence field. The vendor's GitHub organisation has changelogs, demos and a GitHub Action (MIT), but no CLI source. So I call it closed source and do not name it here. This is my own check, not a statement from the vendor.

Commands
git --git-dir=$HOME/code/rea-mirror/rea.git fetch -q origin
git archive <sha> | tar -x -C <dir>
npm run build && npm run docs:check
node scripts/run-development-tests.mjs focused \
  tests/boundary/filesystem/qoderClientConfiguration.test.ts \
  tests/boundary/filesystem/clientLifecycle.test.ts
env -i PATH="$NODE24/bin:/usr/bin:/bin" HOME="$FAKE" TMPDIR="$FAKE/tmp" \
  XDG_CONFIG_HOME="$FAKE/.config" XDG_DATA_HOME="$FAKE/.local/share" \
  XDG_CACHE_HOME="$FAKE/.cache" XDG_STATE_HOME="$FAKE/.local/state" \
  npm_config_cache="$FAKE/.npm" timeout 60 \
  node scripts/rea.mjs setup --client qoder --yes --format json

I ran a dry run first. setup without --yes exits 1 and writes nothing.

Test setup
  • Box: Nobara 44 (Fedora 44 base), Linux 7.2.9
  • CPU: AMD Ryzen 9 5900X, 12 cores / 24 threads
  • RAM: 32 GB DDR4-3600
  • Node: 22.23.1, 24.18.0, 26.11.1
  • Head / base: bd56fe2e9 / 6d8f95e38 (main when I started; the PR's own base is c19e15a2b). I also merge-checked against main 603d04ee3: clean.
  • Other: I did not run a fresh npm ci, because the disk was nearly full. I reused a node_modules from another tree with the same package-lock.json (blob 4b668f798).

🤖 Generated with Claude Code (Sonnet 5.5, verified by Opus 5.5) 🦊

@morluto

morluto commented Oct 11, 2026

Copy link
Copy Markdown
Owner

Reviewed this change and found one setup gap:

[P2] Install Qoder CLI's personal REA skill. The new definition in src/application/SupportedClients.ts:488–494 omits skillPath, based on the claim that Qoder has no documented personal skills directory. The official Qoder CLI Skills documentation explicitly documents ~/.qoder/skills/{skill-name}/SKILL.md and automatic discovery. Setup therefore registers MCP but skips REA's workflow skill. Please add the personal skill destination using Qoder's configuration-location semantics, correct the documentation, and cover skill installation/removal.

The MCP settings path and registration dialect match official documentation. Validation: all six new filesystem tests and 43 shared client-lifecycle tests pass on macOS with Node 24.18.0 and npm 11.16.0. Qoder itself was not executed.

Review follow-up (morluto#1572): the Qoder CLI Skills documentation lists
~/.qoder/skills/{skill-name}/SKILL.md with automatic discovery, so the
definition now carries skillPath following Qoder's configuration
location (QODER_CONFIG_DIR honored) and setup installs the bundled
skill copy there. The installation docs no longer claim Qoder has no
personal skills directory, and the bundled REA skill's supported
client list includes qoder.

Verified: tsc --noEmit clean; vitest run
tests/boundary/filesystem/qoderClientConfiguration.test.ts 7/7.
@IvenKooLab

Copy link
Copy Markdown
Contributor Author

Thanks — fixed in 0c36900.

The definition now carries skillPath following Qoder's configuration-location semantics: the personal skills directory sits beside the config root (join(qoderDirectory(context), "skills")), so it resolves to ~/.qoder/skills by default and follows QODER_CONFIG_DIR when set. Setup installs the bundled REA skill copy there, the installation docs no longer claim Qoder has no personal skills directory, and the bundled skill's supported-client list now includes qoder (the list gap CassieFox23 also noted).

A new test asserts the skill destination with and without QODER_CONFIG_DIR. Validation: qoderClientConfiguration.test.ts 7/7, tsc --noEmit clean, npm run check:fast green.

@morluto
morluto merged commit 1097693 into morluto:main Oct 12, 2026
@morluto

morluto commented Oct 12, 2026

Copy link
Copy Markdown
Owner

Thanks @IvenKooLab for adding Qoder CLI support, including the configuration-directory override and personal skill destination. These are useful additions for Qoder users. Really appreciate the work you put into all three integrations!

@github-actions github-actions Bot mentioned this pull request Oct 12, 2026
3 tasks done
@morluto morluto added enhancement New feature or request area: cli CLI adapter and one-shot commands labels Oct 14, 2026
@morluto morluto added the area: setup Setup, packaging, upgrade, install, Doctor, and client registration label Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: cli CLI adapter and one-shot commands area: setup Setup, packaging, upgrade, install, Doctor, and client registration enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants