Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add project-scope rules support by introducing a shared canonical rules directory:
.agents/rules.When running
dotagentsin project scope, it now symlinks.agents/rulesinto each supported tool’s project rules location:.agents/rules→.claude/rules.agents/rules→.cursor/rules.agents/rules→.github/instructions(GitHub Copilot path-scoped instructions)Related Post:
https://paddo.dev/blog/claude-rules-path-specific-native/
Why
Many tools now support folder-based, path-scoped rules. This change lets you:
.agents/rules)What Changed
rulesmapping in project scope (src/core/mappings.ts)README.md)tests/linking.test.ts)Behavior / Safety
~/.claude,~/.cursor, etc.AGENTS.md/CLAUDE.md/GEMINI.md) in project scope.Notes / Limitations
.agents/rulesfolder is convenient, but you may need tool-specific files for path targeting:paths: src/api/**/*.ts(you can verify what’s active via/memoryin Claude Code)..mdcfiles with fields likeglobs..github/instructionsexpects*.instructions.mdfiles with frontmatter likeapplyTo.backend.md,backend.mdc,backend.instructions.md) and let each tool ignore what it doesn’t understand.Testing
Adds a basic test covering the new rules symlinks (
tests/linking.test.ts)bun test