Ruler skills propagation ignores default_agents and --agents filtering
In ruler v0.3.24, skills are copied to every agent skill directory even though
default_agentsis set to onlyclaudeandgemini-cli, and the same happens with--agentsfiltering. Rules files like CLAUDE.md are filtered correctly, but SKILL.md files are propagated to codex, opencode, pi, agents, vibe, roo, and cursor too. What causes this and how do I fix it?Originally asked on GitHub: https://github.com/intellectronica/ruler/issues/353
2 answers
Fixed in ruler v0.3.34; the issue is closed as resolved.
The bug was in
src/core/SkillsProcessor.ts. ThepropagateSkillsfunction receives the filtered agent list (IAgent[]) but only uses it to check whether any agent supports native skills. Once that check is true, it unconditionally calls the propagation function for every supported agent directory (Claude, Codex, OpenCode, Pi, Goose, Vibe, Roo, Gemini, Cursor). That is why rules filtering worked but skills filtering did not.The issue suggested iterating over the filtered agents array and only propagating skills for agents actually in that list. The maintainer asked a contributor to update the PR, make sure tests pass, and update the docs (comment 2). A later comment reports the resolution in v0.3.34 and the issue was closed.
No workaround was given in the thread. If you cannot upgrade, disabling skills or manually removing the unwanted skill directories after each
ruler applyare options, but those are general suggestions, not maintainer-supported workarounds.Did this work for you?What a GitHub user tried on GitHub (Didn't work)
Reproduced the bug with a minimal
.ruler/ruler.tomlcontainingdefault_agents = ["claude", "gemini-cli"],[skills] enabled = true, and a simpleSKILL.mdin.ruler/skills/commit-message/. Ranruler apply --no-mcp --dry-run -vand observed skills copied to all nine agent skill directories instead of only.claude/skillsand.gemini/skills.Source: https://github.com/intellectronica/ruler/issues/353 (opens external site)
Did this work for you?
Related questions
- Trae AI in ruler: where are project rules and mcp.json stored?
- Does ruler support Amp, and where does it store rules?
- How do I stop ruler apply from creating .bak backup files?
- How can ruler support Roo Code .roorules / .roo/rules/* config files?
- Ruler generates backslashes on Windows, breaks Linux CI sync check