Skip to content

Configuration Reference

The agentsync.toml file is the heart of your agent configuration. It defines the source of truth, how gitignore is managed, and the specific targets for each AI assistant.

By default, agentsync looks for this file at .agents/agentsync.toml.

The base directory for your source files, relative to the configuration file.

  • Default: "."

When enabled, AgentSync creates a compressed copy of AGENTS.md (named AGENTS.compact.md) and points any AGENTS.md targets using type = "symlink" or type = "symlink-contents" to the compressed file. The original AGENTS.md is never modified.

  • Default: false
compress_agents_md = true

A list of agent names to run when --agents is not specified on the CLI. Uses case-insensitive substring matching.

  • Default: [] (empty, meaning all enabled agents will run)
# Only run these agents by default
# When running 'agentsync apply' without --agents, only copilot, claude, and gemini will be processed
default_agents = ["copilot", "claude", "gemini"]
[agents.copilot]
enabled = true
[agents.claude]
enabled = true
[agents.gemini]
enabled = true
[agents.cursor]
enabled = true # Enabled, but won't run unless explicitly specified with --agents cursor

Behavior:

  • If default_agents is set and no --agents flag is provided → runs only agents matching default_agents
  • If --agents flag is provided → uses CLI filter (overrides default_agents)
  • If default_agents is empty → runs all enabled agents (backward compatible)

AgentSync can automatically manage your .gitignore file to ensure that generated symbolic links and agent-specific files are not accidentally committed to version control.

[gitignore]
enabled = true
marker = "AI Agent Symlinks"
# Additional entries only - AgentSync automatically adds known patterns for enabled agents
entries = []
  • enabled: If true, AgentSync will update .gitignore.
  • marker: The text used in comments to identify the AgentSync section in .gitignore.
  • entries: A list of additional file paths to add to the ignore list. This is only needed for files not covered by AgentSync’s known patterns.

AgentSync automatically adds the following patterns to .gitignore based on which agents are enabled:

AgentAutomatically Added Patterns
claude.mcp.json, .claude/commands/, .claude/skills/
copilot.vscode/mcp.json
codex.codex/config.toml
geminiGEMINI.md, .gemini/settings.json, .gemini/commands/, .gemini/skills/
cursor.cursor/mcp.json, .cursor/skills/
vscode.vscode/mcp.json
opencodeopencode.json, .opencode/command/, .opencode/skills/
windsurf.windsurf/mcp_config.json
cline.clinerules
crushCRUSH.md, .crush.json
antigravity.agent/rules/, .agent/skills/
amazonq.amazonq/rules/, .amazonq/mcp.json
aider.aider.conf.yml, .aiderignore
firebase.idx/airules.md, .idx/mcp.json
openhands.openhands/microagents/
junie.junie/
augment.augment/rules/
kilocode.kilocode/mcp.json
goose.goosehints
qwen.qwen/settings.json
roo.roo/mcp.json, .roo/rules/, .roo/skills/
zed.zed/settings.json
trae.trae/rules/
warpWARP.md
kiro.kiro/steering/, .kiro/settings/mcp.json
firebenderfirebender.json
factory.factory/mcp.json, .factory/skills/
vibe.vibe/config.toml, .vibe/skills/
jetbrains.aiassistant/rules/

Notes:

  • The entries field in your config is only needed for additional files not covered by the patterns above
  • All symlink destination paths are also automatically added to .gitignore
  • Duplicate entries are automatically deduplicated

Each assistant is defined under the [agents.<name>] section.

[agents.claude]
enabled = true
description = "Claude Code - Anthropic's AI coding assistant"
[agents.claude.targets.instructions]
source = "AGENTS.md"
destination = "CLAUDE.md"
type = "symlink"
[agents.claude.targets.skills]
source = "skills"
destination = ".claude/skills"
type = "symlink"
[agents.claude.targets.commands]
source = "commands"
destination = ".claude/commands"
type = "symlink-contents"

Skills targets default to type = "symlink". That keeps the agent-facing skills directory as one directory symlink back to the canonical .agents/skills/ source.

  • Use symlink for the common case and for repos already using a correct directory symlink such as .claude/skills -> ../.agents/skills.
  • Use symlink-contents only when the destination must remain a real directory and you want AgentSync to link each child entry individually.
  • agentsync init --wizard now asks explicitly which mode to use for each migrated skills target, recommends symlink, and preserves an already-correct directory symlink by default.

After the wizard writes config, AgentSync runs a compact validation summary. If you override a skills target to symlink-contents while the destination is already a directory symlink to .agents/skills, the summary warns before your first agentsync apply.

AgentSync supports a canonical .agents/commands/ directory for agent commands (slash commands, markdown-based prompts, etc.). Commands are synced to agent-specific locations using symlink-contents.

The init command automatically creates .agents/commands/ alongside .agents/skills/. The wizard detects existing command directories (.claude/commands/, .gemini/commands/, .opencode/command/) and offers to migrate them.

AgentSync has two support levels:

  • Native MCP generation (built-in formatter + merge behavior): claude, copilot, codex, gemini, cursor, vscode, opencode.
  • Configurable sync targets (rules/skills via symlink): any agent as long as you declare [agents.<name>.targets.*] entries.

The matrix below documents common agent locations and whether AgentSync can handle them today.

AgentRules File(s)MCP Configuration / NotesSkills Support / Location
AGENTS.mdAGENTS.mdPseudo-agent pattern via [agents.root] target-
GitHub Copilot.github/copilot-instructions.md.vscode/mcp.json (native MCP)Configurable
Claude CodeCLAUDE.md.mcp.json (native MCP)Configurable; .claude/skills/
OpenAI Codex CLIAGENTS.md.codex/config.toml (native MCP)Configurable; .codex/skills/
Pi Coding Agent-No native MCP formatterConfigurable
Jules-No native MCP formatterConfigurable
Cursor.cursor/rules/agentsync.mdc.cursor/mcp.json (native MCP)Configurable; .cursor/skills/
Windsurf.windsurfrulesNo native MCP formatter; .windsurf/mcp_config.json ignoreConfigurable
Cline.clinerulesNo native MCP formatterConfigurable
CrushCRUSH.mdNo native MCP formatter; .crush.json ignoreConfigurable
AmpAMPCODE.mdNo native MCP formatterConfigurable
Antigravity-No native MCP formatter; .agent/rules/, .agent/skills/ ignoresConfigurable
Amazon Q CLI-No native MCP formatter; .amazonq/rules/, .amazonq/mcp.json ignoresConfigurable
Aider-No native MCP formatter; .aider.conf.yml, .aiderignore ignoresConfigurable
Firebase Studio-No native MCP formatter; .idx/airules.md, .idx/mcp.json ignoresConfigurable
Open Hands-No native MCP formatter; .openhands/microagents/ ignoreConfigurable
Gemini CLIGEMINI.md.gemini/settings.json (native MCP, adds "trust": true)Configurable; .gemini/skills/
Junie-No native MCP formatter; .junie/ ignoreConfigurable
AugmentCode-No native MCP formatter; .augment/rules/ ignoreConfigurable
Kilo Code-No native MCP formatter; .kilocode/mcp.json ignoreConfigurable
OpenCodeOPENCODE.mdopencode.json (native MCP)Configurable; .opencode/skills/
Goose-No native MCP formatter; .goosehints ignoreConfigurable
Qwen Code-No native MCP formatter; .qwen/settings.json ignoreConfigurable
RooCode-No native MCP formatter; .roo/mcp.json, .roo/rules/, .roo/skills/ ignoresConfigurable
Zed-No native MCP formatter; .zed/settings.json ignoreConfigurable
Trae AI-No native MCP formatter; .trae/rules/ ignoreConfigurable
WarpWARP.mdNo native MCP formatterConfigurable
Kiro-No native MCP formatter; .kiro/steering/, .kiro/settings/mcp.json ignoresConfigurable
Firebender-No native MCP formatter; firebender.json ignoreConfigurable
Factory Droid-No native MCP formatter; .factory/mcp.json, .factory/skills/ ignoresConfigurable
Mistral Vibe-No native MCP formatter; .vibe/config.toml, .vibe/skills/ ignoresConfigurable
JetBrains AI Assistant-No native MCP formatter; .aiassistant/rules/ ignoreConfigurable
  • Define the rules target under [agents.<name>.targets.<target-id>].
  • Point source to your canonical file in .agents/ and destination to the tool-specific location.
  • For non-native MCP agents, manage MCP by symlinking a pre-authored config file as another target.
TypeDescription
symlinkCreates a direct symbolic link from destination to source.
symlink-contentsCreates individual symbolic links for every file inside the source directory into the destination directory.
module-mapMaps centrally-managed source files to specific module directories, creating a symlink per mapping with convention-based filenames.

When using symlink-contents, you can filter files using a glob pattern:

[agents.claude.targets.commands]
source = "command"
destination = ".claude/commands"
type = "symlink-contents"
pattern = "*.agent.md"

The module-map type allows you to define a list of mappings between source files and destination directories. This is useful for distributing different context files to specific modules in a project.

By default, AgentSync uses the agent’s convention filename (e.g., CLAUDE.md for Claude) for the symlink name in each destination. You can override this using filename_override.

[agents.claude.targets.modules]
source = "." # Base directory for source files relative to source_dir
destination = "." # Base directory for destinations relative to project root
type = "module-map"
[[agents.claude.targets.modules.mappings]]
source = "api-context.md"
destination = "src/api"
[[agents.claude.targets.modules.mappings]]
source = "ui-context.md"
destination = "src/ui"
filename_override = "CUSTOM-RULES.md"

In this example:

  • src/api/CLAUDE.md will point to .agents/api-context.md
  • src/ui/CUSTOM-RULES.md will point to .agents/ui-context.md

Configuration for MCP servers is managed under the [mcp] and [mcp_servers] sections.

For a detailed guide on how to use MCP with AgentSync, see the MCP Integration Guide .