Search for package-specific usage rules and best practices from Elixir packages. Use when you need coding conventions, patterns, common mistakes, or good/bad examples for packages like Ash, Phoenix, Ecto, etc.
View on GitHubbradleygolden/claude-marketplace-elixir
core
January 20, 2026
Select agents to install to:
npx add-skill https://github.com/bradleygolden/claude-marketplace-elixir/blob/main/plugins/core/skills/usage-rules/SKILL.md -a claude-code --skill usage-rulesInstallation paths:
.claude/skills/usage-rules/# Usage Rules Search Comprehensive search for Elixir and Erlang package usage rules and best practices, following a cascading strategy to find the most relevant coding conventions and patterns. ## When to use this skill Use this skill when you need to: - Look up coding conventions for a Hex package - Find best practices and recommended patterns - See good/bad code examples for proper usage - Understand common mistakes to avoid - Learn package-specific idioms and conventions - Get context-aware recommendations for implementation ## Search strategy This skill implements a **cascading search** that prioritizes local and contextual information: 1. **Local dependencies** - Search installed packages in `deps/` directory for usage-rules.md 2. **Fetched cache** - Check previously fetched usage rules in `.usage-rules/` 3. **Progressive fetch** - Automatically fetch package and extract usage-rules.md if missing 4. **Context-aware extraction** - Extract relevant sections based on coding context 5. **Fallback** - Note when package doesn't provide usage rules, suggest alternatives ## Instructions ### Step 1: Identify the package and context Extract the package name and identify the coding context from the user's question. **Package name examples**: - "Ash best practices" → Package: `ash` - "Phoenix LiveView patterns" → Package: `phoenix_live_view` - "How to use Ecto properly?" → Package: `ecto` **Context keywords**: - Querying: "query", "filter", "search", "find", "list" - Error handling: "error", "validation", "exception", "handle" - Actions: "create", "update", "delete", "action", "change" - Relationships: "relationship", "association", "belongs_to", "has_many" - Testing: "test", "testing", "mock", "fixture" - Authorization: "authorization", "permissions", "policy", "access" - Structure: "structure", "organization", "architecture", "setup" ### Step 2: Search local dependencies Use the **Glob** and **Grep** tools to search the `deps/` directory for usage rules: 1.