metagit-cli
AGENTS.md4 starsChanged 11 days agoMITView on GitHub
Always-loaded project anchor. Read this first. Contains project identity, non-negotiables, commands, and pointer to .mex/ROUTER.md for full context. Use GitNexus MCP tools for all structural and impact analysis.
43 other projects use a version of this, 2 of them edited.
Adopted by
Most recently taken up by
- agentprocess/agentprocesstheir own version, first seen Nov 8, 2026
- OpenMontageInc/OpenMontagetheir own version, first seen Nov 8, 2026
- calesthio/OpenMontagetheir own version, first seen Nov 8, 2026
- akillness/jeo-skillsedited, first seen Nov 6, 2026
- claude-world/director-mode-litetheir own version, first seen Nov 1, 2026
- boadij/pi-herdsmantheir own version, first seen Oct 30, 2026
Other versions43 projects use a version of this.
Word for word · 0
None found.
Edited · 2
- akillness/jeo-skills★ 5411% same
- alewalsh/fhir-mcp-server★ 131% same
Wrote their own version · 41
- calesthio/OpenMontage★ 78ksame name
- OpenMontageInc/OpenMontage★ 78ksame name
- mex-memory/mex★ 1.8ksame name
- theDakshJaitly/mex★ 1.8ksame name
- elevenlabs/skills★ 539same name
- butterbase-ai/butterbase-plugin★ 535same name
- butterbase-ai/butterbase-skills★ 535same name
- tadaspetra/loop★ 296same name
- aws-samples/sample-well-architected-skills-and-steering★ 268same name
- Chinna95P/mpv-anime-build★ 225same name
31 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,774 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository62 other files it gives its agents.
- docs/agents.mdAGENTS.md
- agentsAGENTS.md
- agentsCopilot instructions
- .cursor/rules/github-cli.mdcCursor rule
- .cursor/rules/project-level.mdcCursor rule
- llms.txtllms.txt
- gitnexus-cliSkill
- gitnexus-debuggingSkill
- gitnexus-exploringSkill
- gitnexus-guideSkill
- gitnexus-impact-analysisSkill
- gitnexus-refactoringSkill
- humanizerSkill
- metagit-agent-accessSkill
- metagit-agent-coordinationSkill
- metagit-aosSkill
- metagit-bootstrapSkill
- metagit-campaignSkill
- metagit-cliSkill
- metagit-config-refreshSkill
- metagit-context-packSkill
- metagit-control-centerSkill
- metagit-gatingSkill
- metagit-gitnexusSkill
- metagit-graph-maintainSkill
- metagit-mcp-resourcesSkill
- metagit-multi-repoSkill
- metagit-projectsSkill
- metagit-release-auditSkill
- metagit-repo-impactSkill
- metagit-rewrite-campaignSkill
- metagit-sharing-stateSkill
- metagit-stampSkill
- metagit-upstream-scanSkill
- metagit-upstream-triageSkill
- metagit-workspace-scopeSkill
- metagit-workspace-syncSkill
- metagit-agent-accessSkill
- metagit-agent-coordinationSkill
- metagit-aosSkill
- metagit-bootstrapSkill
- metagit-campaignSkill
- metagit-cliSkill
- metagit-cliSkill
- metagit-config-refreshSkill
- metagit-context-packSkill
- metagit-control-centerSkill
- metagit-gatingSkill
- metagit-gitnexusSkill
- metagit-graph-maintainSkill
- metagit-mcp-resourcesSkill
- metagit-multi-repoSkill
- metagit-projectsSkill
- metagit-release-auditSkill
- metagit-repo-impactSkill
- metagit-rewrite-campaignSkill
- metagit-sharing-stateSkill
- metagit-stampSkill
- metagit-upstream-scanSkill
- metagit-upstream-triageSkill
- The first 60 shown.
The file
We split this AGENTS.md into the rules it gives an agent
9 rules. 0 are common, 3 are distinctive, and 6 are very specific to this project.
0
Common
Most of the 38 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
After meaningful work, run GROW:
- Very specific: line 20
Write: bump last_updated on changed scaffold files and run mex log when rationale matters
- Very specific: line 101
MUST run impact before editing: Use impact({target: "symbolName", direction: "upstream"}) or node .gitnexus/run.cjs impact "symbolName" …
- Very specific: line 102
MUST analyze graph changes before committing: Use detect_changes({scope: "all"}) (MCP) or node .gitnexus/run.cjs detect-changes --scope all …
- Very specific: line 103
MUST warn on HIGH/CRITICAL risk pre-edit.
- Distinctive: line 110
NEVER edit a function, class, or method before MCP/CLI impact analysis.
- Very specific: line 111
NEVER ignore HIGH or CRITICAL risk warnings from impact analysis, and never read UNKNOWN as an all-clear — it means the walk could not …
- Very specific: line 112
NEVER rename symbols with find-and-replace — use rename which understands the call graph.
- Distinctive: line 113
NEVER commit before MCP/CLI graph change analysis.
“Common” is measured: kept by at least 6 in 10 of the 38 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Metagit
What This Is
Metagit gives you situational awareness across Git repositories. It helps multi-repo projects feel manageable, discoverable, and cohesive. It captures cross-repository relationships and project knowledge in easy to understand version controlled manifests.
Day-1 Agent OS loop: docs/agents-quickstart.md — install → context pack → aos next → compile/ACL → complete.
After Every Task
After meaningful work, run GROW:
- Prepare: Run
task qa:prepushand resolve any errors. Rerun until all failures are resolved. - Ground: what changed in reality?
- Record: update
.mex/ROUTER.mdand relevant.mex/context/files - Orient: create or update a
.mex/patterns/runbook if this can recur - Write: bump
last_updatedon changed scaffold files and runmex logwhen rationale matters
Navigation
At the start of every session, read .mex/ROUTER.md before doing anything else.
For full project context, patterns, and task guidance — everything is there.
Metagit — agent quick reference
For agents instructed to use Metagit (not necessarily to contribute to this repository).
Install: uv tool install metagit-cli · set METAGIT_AGENT_MODE=true · PyPI name metagit-cli.
Quickstart: docs/agents-quickstart.md · example examples/agent-aos-loop/
Session start (from repo with .metagit.yml):
metagit -c .metagit.yml context pack --tier 0 --json
metagit -c .metagit.yml prompt workspace --kind session-start --text-onlyLarge umbrellas (500+ repos): keep .metagit.yml on disk. Use search + paged packs + prompt workspace -k large-workspace. Do not run config show --json or workspace list --include-workspace. See docs/reference/context-reduction.md.
Skills: metagit skills install --scope user · MCP: metagit mcp install --scope user
| Need | Command | |||||
| Workspace map / repo cards | metagit context pack --tier 0|1|2 --json | |||||
| Find managed repo | metagit search "…" --json | |||||
| Resolve one repo path | metagit search "…" --path-only (MCP metagit_repo_search path_only: true) | |||||
| List all managed targets | metagit workspace repo list --json (MCP metagit_workspace_repos_list) | |||||
| Repo CI topology | metagit project repo ci show / detect / set (--json) | |||||
| Search repo file contents | metagit workspace grep "…" --json | |||||
| Grep backend (ripgrep) | metagit workspace grep info --json | |||||
| Catalog (paged; no full manifest) | metagit workspace list --json | |||||
| Operational prompts | metagit prompt list | |||||
| Scoped repo text | metagit context repomix --profile bugfix-local --project P --repo R | |||||
| Latest release / notes | metagit version check --json | |||||
| Self-update | metagit version upgrade --apply --json | |||||
| Agent profile / apply | metagit agent profile show / metagit agent apply --vendor cursor | |||||
| Campaigns | metagit campaign list · metagit campaign new · metagit campaign status --limit 40 · metagit campaign expand · metagit campaign board-sync · metagit campaign context | |||||
| Derived surgical project | metagit project derived create -n N --from P/R or P/R/C [--include-dependencies] · refresh · include · exclude | |||||
| Skills surface | metagit skills surface --json | |||||
| ACL isolate agent checkout | metagit branch allocate · metagit lease acquire --allocate · metagit worktree create | |||||
| ACL file claims | metagit claim declare · metagit claim check (--component optional) | |||||
| Task graph / intent | metagit task create · metagit task expand · metagit task ready · metagit task complete | |||||
| Context compile | metagit context compile --project P --repo R [--component NAME] [--depth N] --json | |||||
| Components (RFC-0026–0032) | Nested repos[].components[]; `metagit component list | show | resolve | graph | detect | init; metagit claim declare --component; metagit project derived create --from P/R/C; MCP metagit_component_/metagit_claim_; metagit config validate` · docs/concepts/components.md |
| Context switch | metagit context switch <project> [<repo>] · --json · MCP metagit_context_switch | |||||
| Nav (human) | metagit nav / navigate [--all] [--unmanaged] [--print-path] | |||||
| Semantic ownership | metagit semantic declare · metagit semantic owners · metagit semantic conflicts | |||||
| Merge orchestration | metagit merge enqueue · metagit merge integrate · metagit merge status | |||||
| Agent scheduler | metagit schedule next · metagit schedule status · metagit schedule policy show | |||||
| Agent OS (composition) | metagit aos status · metagit aos doctor · metagit aos next (coord alias) | |||||
| Local Atlas | metagit atlas init · metagit atlas generate · metagit atlas validate · metagit atlas query | |||||
| Organization index | metagit org index github ORG · metagit org search "query" · metagit graph neighbors REPO · metagit repo materialize REPO | |||||
| Agent coordination skill | metagit skills show metagit-agent-coordination | |||||
| Agent OS skill | metagit skills show metagit-aos | |||||
| Agent coordination (ACL) | docs/reference/agent-coordination.md | |||||
| Task graph (RFC-0008) | docs/reference/task-graph.md | |||||
| Context compiler (RFC-0009) | docs/reference/context-compiler.md | |||||
| Semantic ownership (RFC-0010) | docs/reference/semantic-ownership.md | |||||
| Merge orchestrator (RFC-0011) | docs/reference/merge-orchestrator.md | |||||
| Agent scheduler (RFC-0012) | docs/reference/agent-scheduler.md | |||||
| Agent OS (RFC-0013) | docs/reference/aos.md | |||||
| Metagit Atlas (RFC-0014) | docs/reference/atlas.md | |||||
| Feature registry (all modalities) | docs/reference/modality-feature-registry.md |
Full guide: docs/agents.md · Index: llms.txt · Skills: docs/skills.md · Docs: https://metagit-ai.github.io/metagit-cli/agents/
<!-- gitnexus:start -->GitNexus — Code Intelligence
This project is indexed by GitNexus as metagit-cli (17846 symbols, 38515 relationships, 1008 execution flows).
Index stale? Run
node .gitnexus/run.cjs analyze --index-onlyfrom the project root — it auto-selects an available runner. No.gitnexus/run.cjsyet? Bootstrap withnpx,bunx, orpnpm dlx— e.g.bunx gitnexus@latest analyze(npm 11 npx crash; #1939).
Always Do
- MUST run impact before editing. Use
impact({target: "symbolName", direction: "upstream"})ornode .gitnexus/run.cjs impact "symbolName" --direction upstream --repo .; report callers, processes, and risk. Never substitute grep for graph analysis. - MUST analyze graph changes before committing. Use
detect_changes({scope: "all"})(MCP) ornode .gitnexus/run.cjs detect-changes --scope all --repo .(CLI fallback).partial: trueortruncated: trueis not a clean check — a zero means unseen, not unaffected; re-run it. For regression review:detect_changes({scope: "compare", base_ref: "main"})ornode .gitnexus/run.cjs detect-changes --scope compare --base-ref "main" --repo .. - MUST warn on HIGH/CRITICAL
riskpre-edit; never useriskSharedAxesto waive a HIGH/CRITICALriskwarning. Compare File/symbol: MCP File omits axes; Graph-RAG expands File. - MUST treat
risk: UNKNOWNas unresolved, not as low. An empty caller set is not evidence the symbol is unused — it can also mean the callers are not resolvable by the index (plain-object property access, dynamic dispatch, cross-language calls).impactpairsUNKNOWNwith ariskNotesaying so. Confirm with a text search before treating the symbol as safe to change or delete; do not proceed on the strength of a zero. - MUST use
query({search_query: "concept"})for concepts/flows,context({name: "symbolName"})for a named symbol, orimpactfor blast radius, on read-only callers, dependencies, imports, or execution flow. Graph first; text search only for empty/UNKNOWN/literals. - For security review,
explain({target: "fileOrSymbol"})lists taint findings (source→sink flows; needsanalyze --pdg).
Never Do
- NEVER edit a function, class, or method before MCP/CLI impact analysis.
- NEVER ignore HIGH or CRITICAL risk warnings from impact analysis, and never read
UNKNOWNas an all-clear — it means the walk could not answer, which is the one verdict that requires confirming by other means. - NEVER rename symbols with find-and-replace — use
renamewhich understands the call graph. - NEVER commit before MCP/CLI graph change analysis.
Resources
| Resource | Use for |
gitnexus://repo/metagit-cli/context | Codebase overview, check index freshness |
gitnexus://repo/metagit-cli/clusters | All functional areas |
gitnexus://repo/metagit-cli/processes | All execution flows |
gitnexus://repo/metagit-cli/process/{name} | Step-by-step execution trace |
CLI
| Task | Read this skill file |
| Understand architecture / "How does X work?" | .claude/skills/gitnexus-exploring/SKILL.md |
| Blast radius / "What breaks if I change X?" | .claude/skills/gitnexus-impact-analysis/SKILL.md |
| Trace bugs / "Why is X failing?" | .claude/skills/gitnexus-debugging/SKILL.md |
| Rename / extract / split / refactor | .claude/skills/gitnexus-refactoring/SKILL.md |
| Tools, resources, schema reference | .claude/skills/gitnexus-guide/SKILL.md |
| Index, status, clean, wiki CLI commands | .claude/skills/gitnexus-cli/SKILL.md |
<!-- gitnexus:end -->Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

