/alfred-codebase:stay-in-the-linesfrom alfred-codebase
Enforces project architecture rules: module import restrictions, cycle prevention, and API-only service communication. Reports violations with commit origin and suggested fixes.
Ships in alfred-codebase. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Look for a boundaries JSON block in PLAN.md, then ARCHITECTURE.md, then lint rules (eslint import rules, dependency-cruiser, ArchUnit, import-linter). If there are none, propose a few from how the code is laid out today, show them to the user, and add them to PLAN.md only once they agree:
{
"boundaries": [
{ "rule": "ui-never-imports-db", "from": "src/app/**", "to": "src/db/**", "type": "forbidden" },
{ "rule": "services-talk-over-api", "from": "services/a/**", "to": "services/b/**", "type": "no-direct-import" },
{ "rule": "no-cycles", "scope": "**", "type": "no-cycle" }
]
}
Rule types: forbidden (A must never import B), no-direct-import (go through the API), no-cycle, ownership (this logic lives only in its owner module).
rg and the language's import syntax.For each violation: the rule, the exact import or call (file:line), the commit that added it (git log -S), and the fix that keeps the rule's intent. Report each once.
Never fix a violation without asking. Sometimes the rule is what's wrong; say so when it is.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub wednesday-solutions/alfred --plugin alfred-codebase7 skills in this plugin
/audit-a-moduleHealth check one module or service and recommend what to do with it: leave it, clean it up, refactor it with care, or don't touch it without a senior. Covers what it does, who depends on it, risk, test coverage, churn and rule breaks. Use when the user says "audit this module", "is it safe to refactor X", "how healthy is this service" or "should we rewrite X"./deploy-without-fearCheck everything before and after a production deploy, with a rollback plan and clear rollback triggers. Use when the user is about to deploy or just deployed, or says "is it safe to deploy", "pre-deploy check", "post-deploy check" or "we're going to prod". Not for committing, opening PRs or app store releases./learn-this-codebaseGet to know an unfamiliar codebase fast. Maps what it does, its modules, entry points, riskiest files, recent changes and the rules not to break, writes it to CODEBASE.md, then answers questions from that map with sources. Use when the user is new to a project or says "onboard me", "where do I start", "how does X work here", "where is the payment logic" or "give me an overview"./plan-from-scratchPlan a new project before any code exists. Researches the domain, then has an architect, a product lead and a security lead plan it independently, and merges them into one PLAN.md that names where they disagree. Use when the user is starting something new and says "plan this", "help me start this project", "write a PLAN.md" or "what should the stack be". Not for changes to an existing codebase (use learn-this-codebase first)./see-what-a-change-breaksBefore editing a file or symbol, find everything that depends on it, score how risky the change is, and stop for approval when it's high. Use before changing a shared function, type, API, schema or config, or when the user asks "is it safe to change this", "what breaks if I change X" or "what's the blast radius"./tests-for-old-codeAdd end-to-end tests to code that has none, in tiers by confidence, and run every test before handing it over. Use before refactoring untested code, after inheriting a project, or when the user says "add tests for this flow", "write e2e tests for login" or "we have no tests for X".Other plugins' skills for the same job