Write AI coding rules once, sync to every agent.
Most developers already have an AGENTS.md or CLAUDE.md in their projects. agent-dotfiles reads your existing rules and propagates them to every coding agent you use. No new directories, no config files, no lock-in.
| Agent | Rules | Skills | Detection |
|---|---|---|---|
| Command Code | AGENTS.md |
.commandcode/skills/ |
~/.commandcode |
| Claude Code | CLAUDE.md |
.claude/skills/ |
~/.claude |
| Cursor | AGENTS.md |
.cursor/skills/ |
~/.cursor |
| Copilot | AGENTS.md |
.github/skills/ |
~/.copilot |
| Codex | AGENTS.md |
.agents/skills/ |
~/.codex |
| OpenCode | AGENTS.md |
.opencode/skills/ |
~/.config/opencode |
npx agent-dotfilesRun without arguments to see detected agents, found rules, and available commands:
npx agent-dotfilesSync your rules file to all agents:
npx agent-dotfiles sync rules --from AGENTS.md --to allSync to specific agents:
npx agent-dotfiles sync rules --from AGENTS.md --to claude,cursornpx agent-dotfiles sync skills --from .claude/skills --to allSync global rules across agents:
npx agent-dotfiles sync rules --from ~/.claude/CLAUDE.md --to all --globalPreview what would happen without writing files:
npx agent-dotfiles sync rules --from AGENTS.md --to all --dry-run| Flag | Description | Default |
|---|---|---|
--from <source> |
Source rules file or skills directory | required |
--to <agents> |
Target agents (comma-separated or all) |
all |
--strategy <s> |
skip, overwrite, or merge |
skip |
--method <m> |
copy or symlink |
copy |
--global |
Sync global rules/skills | false |
--dry-run |
Preview without writing | false |
- skip (default) — never overwrites existing files
- overwrite — replaces existing files with source content
- merge — appends source content to existing files
Optional config at ~/.agents/agent-dotfiles.json:
{
"mergeStrategy": "skip",
"writeMethod": "copy"
}agent-dotfiles is a propagator, not a creator. It reads your existing rules files and syncs them to agent-specific locations. Smart enough to skip agents that already natively read your source file.
For example, syncing from AGENTS.md:
- Skips Command Code, Cursor, Codex, OpenCode (they already read
AGENTS.md) - Creates
CLAUDE.mdfor Claude Code (it only readsCLAUDE.md)
We welcome contributions — especially adding support for new coding agents! Check out the Contributing Guide for a step-by-step walkthrough.
MIT
Built by Saqib with Command Code