phx-techdebt
Analyze Elixir/Phoenix technical debt — duplicates, refactoring opportunities, credo issues. Use when asked about code quality, cleanup, or what to improve.
npx skills add oliver-kriska/claude-elixir-phoenix --skill phx-techdebt --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Technical Debt Detection Find and eliminate duplicate code patterns, anti-patterns, and refactoring opportunities in Elixir/Phoenix projects. ## Iron Laws - Never Violate These 1. **Search before refactoring** - Understand full scope of duplication before extracting 2. **Three strikes rule** - Extract shared code only after 3+ duplications 3. **Prefer composition** - Use behaviours and protocols over inheritance-style abstractions 4. **Test coverage first** - Ensure tests exist before refactoring duplicated code ## Analysis Checklist ### 1. Run Credo for Automated Detection Run `mix credo --strict`. Focus on: - Design issues (duplication, complexity) - Consistency issues (naming, patterns) - Refactoring opportunities ### 2. Find Duplicate Ecto Query Patterns Use Grep to search for repeated Repo calls (`Repo.get!`, `Repo.get`, `Repo.one`) in `lib/**/*.ex`. Use Grep to find duplicate query patterns (`from.*in.*where`) in `lib/**/*.ex`. ### 3. Find Duplicate Validation Logic Use Grep with `output_mode: "count"` to count `def changeset` occurrences in `lib/**/*.ex`. Use Grep to find repeated validations (`validate_required`, `validate_format`) in `lib/**/*.ex`. ### 4. Find Copy-Paste
- Iron Laws - Never Violate These
- Analysis Checklist
- 1. Run Credo for Automated Detection
- 2. Find Duplicate Ecto Query Patterns
- 3. Find Duplicate Validation Logic
- 4. Find Copy-Pasted Controller Actions
- Common Duplication Patterns
- Reporting Format
- Usage
What does the phx-techdebt skill do?
Analyze Elixir/Phoenix technical debt — duplicates, refactoring opportunities, credo issues. Use when asked about code quality, cleanup, or what to improve.
How do I install it?
Run `npx skills add oliver-kriska/claude-elixir-phoenix --skill phx-techdebt --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From oliver-kriska/claude-elixir-phoenix, a repository with 515 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
