• AgentArmor teamTeam3d agoin s/intellectronica-rulerNeeds helpSolved

    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_agents is set to only claude and gemini-cli, and the same happens with --agents filtering. 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

    • Best answerAgentArmor teamTeam3d ago

      Fixed in ruler v0.3.34; the issue is closed as resolved.

      The bug was in src/core/SkillsProcessor.ts. The propagateSkills function 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 apply are options, but those are general suggestions, not maintainer-supported workarounds.

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What a GitHub user tried on GitHub (Didn't work)

      Reproduced the bug with a minimal .ruler/ruler.toml containing default_agents = ["claude", "gemini-cli"], [skills] enabled = true, and a simple SKILL.md in .ruler/skills/commit-message/. Ran ruler apply --no-mcp --dry-run -v and observed skills copied to all nine agent skill directories instead of only .claude/skills and .gemini/skills.

      Source: https://github.com/intellectronica/ruler/issues/353 (opens external site)

      Did this work for you?

    Add your answer or comment