# AgentsMesh CLI > One config for every AI coding tool, with a shared lessons memory that learns from your repo. ## Pages - [AI coding config sync for Claude Code, Cursor, Copilot and more](https://samplexbro.github.io/agentsmesh/): One .agentsmesh source syncs rules, commands, skills, MCP servers, hooks and permissions to every AI coding tool. Open source, with a memory that learns. - [Canonical Configuration](https://samplexbro.github.io/agentsmesh/canonical-config/): The .agentsmesh/ directory is the single source of truth for all AI tool configuration in AgentsMesh. Learn the directory structure and file formats. - [Agents](https://samplexbro.github.io/agentsmesh/canonical-config/agents/): Agents define custom subagents with their own tools, model, permissions, hooks, and skills. Stored in .agentsmesh/agents/ as Markdown files with YAML frontmatter. - [Commands](https://samplexbro.github.io/agentsmesh/canonical-config/commands/): Commands are reusable slash-command prompts in AgentsMesh. They map to native slash commands in tools that support them, and are projected as skills in tools that don't. - [Hooks](https://samplexbro.github.io/agentsmesh/canonical-config/hooks/): Lifecycle hooks in AgentsMesh trigger shell commands or prompt injections before/after tool use, on notifications, on user prompts, and on subagent lifecycle events. - [Ignore Patterns](https://samplexbro.github.io/agentsmesh/canonical-config/ignore-patterns/): The AgentsMesh ignore file uses gitignore syntax to tell AI tools which files and directories to skip when indexing or reading the project. - [MCP Servers](https://samplexbro.github.io/agentsmesh/canonical-config/mcp-servers/): MCP server definitions in AgentsMesh use a JSON format compatible with the Model Context Protocol. Define stdio and HTTP servers once, generate for all supported tools. - [Permissions](https://samplexbro.github.io/agentsmesh/canonical-config/permissions/): Permissions in AgentsMesh define allow and deny lists for tool operations. Support varies per target — see the supported tools matrix. - [Rules](https://samplexbro.github.io/agentsmesh/canonical-config/rules/): Rules are markdown files with optional YAML frontmatter that define guidelines for AI coding tools. The root rule is always applied; additional rules can be scoped by target or file pattern. - [Skills](https://samplexbro.github.io/agentsmesh/canonical-config/skills/): Skills are directories containing a SKILL.md definition and optional supporting files. They are reusable capability bundles referenced by agents and commands. - [CLI Reference](https://samplexbro.github.io/agentsmesh/cli/): Complete reference for all AgentsMesh CLI commands — init, generate, import, convert, install, uninstall, installs, refresh, diff, lint, watch, check, merge, matrix, plugin, and target. Both project and global mode supported. - [agentsmesh check](https://samplexbro.github.io/agentsmesh/cli/check/): Verify that canonical files still match the lock file. Designed for CI pipelines — exits with code 1 if generated files have drifted from the lock. - [agentsmesh convert — Cursor rules to CLAUDE.md, AGENTS.md or Copilot](https://samplexbro.github.io/agentsmesh/cli/convert/): Convert Cursor .mdc rules to CLAUDE.md, AGENTS.md or copilot-instructions.md in one command, keeping globs and activation modes. No canonical setup required. - [agentsmesh diff](https://samplexbro.github.io/agentsmesh/cli/diff/): Show a unified diff of what the next agentsmesh generate would change, without writing any files. Useful for reviewing pending changes before committing. - [agentsmesh generate](https://samplexbro.github.io/agentsmesh/cli/generate/): Generate target-specific config files from the canonical .agentsmesh/ directory. Supports dry-run, target filtering, CI check mode, and cache refresh. - [agentsmesh import](https://samplexbro.github.io/agentsmesh/cli/import/): Import an existing AI tool's configuration into the canonical .agentsmesh/ directory. Supports all targets with lossless round-trip fidelity. - [agentsmesh init — generate AGENTS.md and canonical config](https://samplexbro.github.io/agentsmesh/cli/init/): Generate AGENTS.md, CLAUDE.md and every other tool file from one source. Scaffolds .agentsmesh/ and agentsmesh.yaml, detects the tools you already use, and imports their config. - [agentsmesh install](https://samplexbro.github.io/agentsmesh/cli/install/): Install rules, commands, agents, or skills from GitHub, GitLab, git URLs, or local paths. Manage community packs and shared organizational config. - [agentsmesh installs](https://samplexbro.github.io/agentsmesh/cli/installs/): Read-only inventory of installed packs. List installed packs with name, source, features, and install date. - [agentsmesh lessons](https://samplexbro.github.io/agentsmesh/cli/lessons/): Query and capture lessons from .agentsmesh/lessons/lessons.json — the universal recall/capture graph that any harness can read through one shell primitive. - [agentsmesh lint](https://samplexbro.github.io/agentsmesh/cli/lint/): Validate canonical files against target-specific constraints. Catches frontmatter errors, format violations, and schema issues before generation. - [agentsmesh matrix](https://samplexbro.github.io/agentsmesh/cli/matrix/): Display the feature-target compatibility matrix for your current AgentsMesh configuration. Shows which features are supported natively, embedded, or unsupported per tool. - [agentsmesh mcp](https://samplexbro.github.io/agentsmesh/cli/mcp/): Start the AgentsMesh self-serve MCP server over stdio. Exposes canonical .agentsmesh/ config to AI agents as tools and resources. - [agentsmesh merge](https://samplexbro.github.io/agentsmesh/cli/merge/): Resolve .agentsmesh/.lock merge conflicts after a git merge. Rebuilds the lock file from the current canonical state. - [agentsmesh plugin](https://samplexbro.github.io/agentsmesh/cli/plugin/): Manage AgentsMesh plugin targets — install, list, inspect, and remove third-party AI tool descriptors that ship as standalone npm packages with full built-in parity. - [agentsmesh refresh](https://samplexbro.github.io/agentsmesh/cli/refresh/): Re-fetch and re-apply installed packs from their recorded sources. Branch pins advance to the current tip; SHA pins stay put. Per-pack atomic. - [agentsmesh target](https://samplexbro.github.io/agentsmesh/cli/target/): Scaffold a new built-in target for AgentsMesh — generates the descriptor, generator, importer, linter, tests, and fixtures so the new target is auto-discovered at build time. - [agentsmesh uninstall](https://samplexbro.github.io/agentsmesh/cli/uninstall/): Remove an installed pack. Cleans .agentsmesh/packs/, installs.yaml, extends entries, and generated outputs. - [agentsmesh watch](https://samplexbro.github.io/agentsmesh/cli/watch/): Watch the .agentsmesh/ directory for changes and automatically regenerate on save. Uses a 300ms debounce to batch rapid edits. - [agentsmesh.yaml](https://samplexbro.github.io/agentsmesh/configuration/agentsmesh-yaml/): Complete reference for agentsmesh.yaml — the main project configuration file for AgentsMesh. Configure targets, features, extends, overrides, and collaboration settings. - [Collaboration Settings](https://samplexbro.github.io/agentsmesh/configuration/collaboration/): Configure how teams work with generated AgentsMesh config — merge strategies, feature locking, and conflict resolution for multi-developer projects. - [Conversions](https://samplexbro.github.io/agentsmesh/configuration/conversions/): Control how AgentsMesh projects features to tools that lack native support — commands to skills, agents to skills, and more. - [Extends](https://samplexbro.github.io/agentsmesh/configuration/extends/): Pull shared rules, commands, agents, and skills from remote repositories, other local projects, or Git URLs using the extends field in agentsmesh.yaml. - [Local Overrides](https://samplexbro.github.io/agentsmesh/configuration/local-overrides/): agentsmesh.local.yaml is gitignored and lets individual developers customize their local setup without affecting the shared team config. - [Installation](https://samplexbro.github.io/agentsmesh/getting-started/installation/): Install AgentsMesh via Homebrew, a standalone binary, or any Node.js package manager (npm, pnpm, yarn, npx). Works on Linux, macOS, and Windows. - [Quick Start](https://samplexbro.github.io/agentsmesh/getting-started/quick-start/): Get AgentsMesh running in under 5 minutes — scaffold a new canonical config directory or import your existing AI tool configs. - [Building Plugins](https://samplexbro.github.io/agentsmesh/guides/building-plugins/): Build an AgentsMesh plugin that generates config files for any AI coding tool — from a minimal rule generator to full feature parity with built-in targets. - [Keep CLAUDE.md, AGENTS.md and .cursor/rules in sync](https://samplexbro.github.io/agentsmesh/guides/ci-drift-detection/): Stop CLAUDE.md, AGENTS.md and .cursor/rules drifting apart. Use agentsmesh check and lint in CI to fail the build when one tool’s config no longer matches the others. - [CLAUDE.md vs AGENTS.md](https://samplexbro.github.io/agentsmesh/guides/claude-md-vs-agents-md/): Claude Code 2.1.277 reads AGENTS.md when there is no CLAUDE.md. What that fallback covers, the five ways it surprises people, and which parts of your agent config are still per-tool. - [Installing Community Packs](https://samplexbro.github.io/agentsmesh/guides/community-packs/): Install shared rules, commands, agents, and skills from public repositories using agentsmesh install. Manage packs with installs.yaml. - [Adopting AgentsMesh in an Existing Project](https://samplexbro.github.io/agentsmesh/guides/existing-project/): Step-by-step guide to adopting AgentsMesh in a project that already has AI tool configs in .claude/, .cursor/, .cline/, and other tool directories. - [Extending AgentsMesh](https://samplexbro.github.io/agentsmesh/guides/extending/): Add new AI tool targets via the scaffolder or the plugin system. - [Installing Anthropic-style skill packs](https://samplexbro.github.io/agentsmesh/guides/installing-skill-packs/): Walk through agentsmesh install on a community skill pack (addyosmani/agent-skills). Bulk-select, broken-link prompts, and uninstall round-trip. - [Teach Your AI Agents with Lessons](https://samplexbro.github.io/agentsmesh/guides/lessons/): Give AI coding agents a shared memory that learns from your repo — capture a rule after every failure, recall it before every edit, in any AI tool. - [Local Development Overrides](https://samplexbro.github.io/agentsmesh/guides/local-overrides/): Use agentsmesh.local.yaml to customize your personal AgentsMesh setup without affecting teammates. Narrow targets, skip features, or tune watch mode. - [Supporting Multiple Tools on a Team](https://samplexbro.github.io/agentsmesh/guides/multi-tool-teams/): Configure AgentsMesh to generate config for every tool your team uses, so Claude Code users and Cursor users share the same rules without manual sync. - [One mcp.json for Claude Code, Cursor, Codex and Gemini](https://samplexbro.github.io/agentsmesh/guides/one-mcp-json/): The same MCP server has to be declared in four different file formats, including TOML. Write it once in .agentsmesh/mcp.json and generate every tool's native shape. - [Sharing Config Across Repositories](https://samplexbro.github.io/agentsmesh/guides/sharing-config/): Use AgentsMesh extends to pull shared rules, commands, and agents from an organizational config repository into multiple projects. - [AgentsMesh as a rulesync alternative or Ruler alternative](https://samplexbro.github.io/agentsmesh/reference/alternatives/): How AgentsMesh compares to Ruler, rulesync, and the AGENTS.md standard for syncing AI coding assistant config — a Ruler/rulesync alternative with a shared lessons memory, lossless two-way import, cross-tool link rebasing, and plugins. - [Generation Pipeline](https://samplexbro.github.io/agentsmesh/reference/generation-pipeline/): How AgentsMesh transforms canonical .agentsmesh/ sources into target-specific config files — the 7-step generation pipeline and import reverse pipeline. - [JSON Schemas (IDE autocomplete)](https://samplexbro.github.io/agentsmesh/reference/json-schemas/): AgentsMesh ships pinned JSON Schemas for every config file it writes — agentsmesh.yaml, installs.yaml, pack.yaml, install-manifest.json, mcp.json, hooks.yaml, permissions.yaml. Editors auto-detect them with zero configuration. - [Lessons graph reference](https://samplexbro.github.io/agentsmesh/reference/lessons/): Schema, validation codes, and programmatic API for .agentsmesh/lessons/lessons.json — the universal recall/capture graph. - [Managed Embedding](https://samplexbro.github.io/agentsmesh/reference/managed-embedding/): The AgentsMesh marker contract for embedding generated or recoverable canonical content inside agent tool files without duplicates or broken round trips. - [MCP Server (Self-Serve)](https://samplexbro.github.io/agentsmesh/reference/mcp-server/): AgentsMesh exposes itself as an MCP server so AI agents can introspect and mutate their own canonical configuration — rules, commands, agents, skills, settings, orchestration, and pack lifecycle — all over stdio. - [Programmatic API](https://samplexbro.github.io/agentsmesh/reference/programmatic-api/): AgentsMesh as a typed ESM library — load config, generate, lint, diff, check, import, register plugins, and the full error taxonomy. Drive every CLI capability from a script, IDE extension, or CI runner. - [Supported Tools Matrix](https://samplexbro.github.io/agentsmesh/reference/supported-tools/): Complete feature-target compatibility matrix for every AI coding tool supported by AgentsMesh, including Claude Code, Cursor, Copilot, Continue, Junie, Kiro, Gemini CLI, Cline, Codex CLI, Windsurf, Antigravity, Roo Code, Amp, Zed, Warp, and more as they ship.