Skip to content

Make AGENTS.md canonical and reach every runtime (stack 3/5) - #44

Closed
martient wants to merge 1 commit into
claude/ai-agents-capabilities-report-fgpp3p-ai-fixesfrom
claude/ai-agents-capabilities-report-fgpp3p-cross-tool
Closed

martient wants to merge 1 commit into
claude/ai-agents-capabilities-report-fgpp3p-ai-fixesfrom
claude/ai-agents-capabilities-report-fgpp3p-cross-tool

Conversation

@martient

@martient martient commented Sep 20, 2026 •

Copy link
Copy Markdown
Owner

Stacked on #43. Resolves P1-8, P1-9, P1-10, P1-11 and P2-14.

One instruction file, not two

AGENTS.md and CLAUDE.md were near-identical files kept in sync by hand — a two-line diff that had already started drifting: the AI-attribution-trailer ban landed in CLAUDE.md only. AGENTS.md is now the single source; CLAUDE.md is an @AGENTS.md import plus the one genuinely Claude-specific line (slash-command invocation), which is the pattern the ecosystem settled on.

Two widely-deployed runtimes read neither file, so they get thin pointers: .github/copilot-instructions.md and GEMINI.md.

Cross-tool skill discovery

.agents/skills is the path Codex CLI, the Codex app, Claude Code and Copilot CLI all resolve. It now exists as a symlink to the canonical plugins/committy/skills, so there is no second copy to drift.

⚠️ Reviewer note on the symlink. A checkout that materialises it as a plain text file — Windows without developer mode, or core.symlinks=false — silently breaks discovery for every runtime reading that path. test_skills_are_discoverable_at_the_cross_tool_path fails loudly in that case rather than letting it pass unnoticed. If you'd rather not depend on symlinks at all, the alternative is moving the canonical copy to .agents/skills and pointing both plugin manifests there; I didn't take it because I can't verify from here whether Claude's plugin.json accepts a skills path outside the plugin directory.

Skill frontmatter

All four skills carried only name and description. They now add the spec's optional fields:

  • license: Apache-2.0
  • allowed-tools — so security-conscious runtimes pre-authorise exactly what each skill needs (committy-enforce is the only one granted Edit/Write, since it installs hooks and CI)
  • metadata — a skill version independent of the CLI version, plus the minimum Committy it expects

Codex syntax in a shared body

committy-release/SKILL.md referenced siblings as $committy-commit. That body is shared by both runtimes, and Claude Code invokes them as /committy:committy-commit. Siblings are now named plainly and each runtime resolves them its own way.

Test contract change

test_agent_docs_mention_the_non_interactive_env_var previously required every agent-facing file to contain COMMITTY_NONINTERACTIVE verbatim. With one canonical file that is wrong, so it now accepts a file that either states the rule or defers to AGENTS.md — and covers the two new pointer files too.

Verification

375 passed, fmt clean, clippy -D warnings clean. The pre-existing tag_tests failure noted in #42 is unchanged.

AGENTS.md and CLAUDE.md were near-identical files kept in sync by hand;
the diff was two lines and had already started drifting (the trailer ban
landed in one of them only). AGENTS.md is now the single source and
CLAUDE.md is an @AGENTS.md import plus the one genuinely Claude-specific
line, which is the pattern the ecosystem settled on.

Two runtimes read neither file, so they now get thin pointers:
.github/copilot-instructions.md and GEMINI.md.

Skills are exposed at .agents/skills, the cross-tool discovery path that
Codex, Claude Code and Copilot CLI all resolve, via a symlink to the
canonical copy under plugins/committy/skills -- no duplication. A test
guards the symlink, because a checkout that materialises it as a plain
file would break discovery silently.

Skill frontmatter gains the spec's optional fields: license,
allowed-tools (so security-conscious runtimes can pre-authorise exactly
what each skill needs) and metadata carrying a skill version independent
of the CLI version.

committy-release referenced siblings with Codex's `$skill` syntax inside
a body shared by both runtimes; they are now named plainly and each
runtime resolves them its own way.

The COMMITTY_NONINTERACTIVE docs test now accepts a file that defers to
AGENTS.md rather than restating it, which is what the split requires.

Copy link
Copy Markdown
Owner Author

Superseded by #49, which carries these commits unchanged. Closing — see #42 for why the stack was collapsed.


Generated by Claude Code

@martient martient closed this Sep 20, 2026
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.

2 participants