Skip to content

feat: register Gemini CLI host with dedicated .gemini subdir#2309

Open
fischer33 wants to merge 3 commits into
garrytan:mainfrom
fischer33:feat/edge-substance
Open

feat: register Gemini CLI host with dedicated .gemini subdir#2309
fischer33 wants to merge 3 commits into
garrytan:mainfrom
fischer33:feat/edge-substance

Conversation

@fischer33

Copy link
Copy Markdown

Summary

  • Registers Gemini CLI as a new gstack host, wired into hosts/index.ts (ALL_HOST_CONFIGS) so the skill-doc pipeline generates Gemini-flavored output.
  • Gives Gemini a dedicated .gemini namespace (globalRoot, localSkillRoot, hostSubdir) instead of reusing Codex's .agents output dir — the two would otherwise collide on the tested unique hostSubdir / unique globalRoot invariants.
  • Path rewrites retarget skill paths and CLAUDE.mdGEMINI.md; tool rewrites map Claude tools to Gemini equivalents (Bashrun_shell_command, Readread_file, Writewrite_file, Editreplace_in_file, Agentdelegate_to_agent, Globlist_directory, Grepsearch_files).
  • Bumps the host-count assertion in test/host-config.test.ts (10 → 11) to keep the suite green.
  • Gitignores the generated .gemini/ output dir (matches the pattern for every other host's generated output).

Why .gemini and not .agents

hostSubdir is the render output directory (gen-skill-docs.ts writes generated SKILL.md there), and uniqueness is a tested invariant enforced by validateAllConfigs(). Codex already owns .agents (its CLI alias is literally agents), so the shared subdir was a copy-paste leftover, not a deliberate shared workspace. Gemini gets its own .gemini.

Test plan

  • bun test test/host-config.test.ts — host-config suite passes (69 pass / 4 fail; the 4 failures pre-exist on the base branch and are unrelated: opencode env-detection + gbrain golden-file drift; verified via stash baseline).
  • bun run gen:skill-docs — all 47 skills generate for the gemini host with correct path transformations (26 .gemini refs, 0 .agents leaks, CLAUDE.mdGEMINI.md rewrite verified).

🤖 Generated with Claude Code

.serena/, graphify-out/, and shopify-oauth/ are local artifacts (Serena MCP
cache, graphify skill output) and an unrelated nested Next.js project. They
were showing as untracked noise; ignore them so the working tree stays clean.
Wire the previously-unregistered Gemini CLI HostConfig into the registry.
The rescued config reused Codex's .agents hostSubdir, which collides with
codex under validateAllConfigs (hostSubdir/globalRoot must be unique).
Retarget Gemini to its native .gemini home (matching its GEMINI.md rewrite
and Google's Gemini CLI convention) and bump the host-count assertion 10 -> 11.
Generated per-host skill dirs are not committed (matches .agents, .hermes, etc).
@trunk-io

trunk-io Bot commented Jul 20, 2026

Copy link
Copy Markdown

Merging to main in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant