Help us improve
Share bugs, ideas, or general feedback.
From solid-coder
Write SOLID-compliant code with principle rules loaded as constraints. Takes a prompt, a spec file, or both.
npx claudepluginhub swift-gurus/solid-coderHow this skill is triggered — by the user, by Claude, or both
Slash command
/solid-coder:codeThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Write or modify code with SOLID principle rules loaded as active constraints. The rules define what constitutes a violation — this skill knows how to write code that doesn't violate.
Mandates invoking relevant skills via tools before any response in coding sessions. Covers access, priorities, and adaptations for Claude Code, Copilot CLI, Gemini CLI.
Share bugs, ideas, or general feedback.
Write or modify code with SOLID principle rules loaded as active constraints. The rules define what constitutes a violation — this skill knows how to write code that doesn't violate.
refactor, implement, or coderefactor: PLANS_DIR = $ARGUMENTS[1] (directory containing .plan.json files), OUTPUT_ROOT = $ARGUMENTS[2]implement: PLAN_DIR = $ARGUMENTS[1] (directory containing chunk files: 01-plan.json, 02-plan.json, etc.)code: PROMPT = $ARGUMENTS[1..] (spec file path, inline prompt, or both)Read MODE and load context for that mode.
{PLANS_DIR}/*.plan.json to discover all plan files → PLAN_FILES listfile_path + actions[]file_path as the target source filedepends_on). For each action: use todo_items as implementation steps, suggested_fix as reference code, resolves for traceability{PLAN_DIR}/*.json and sort alphabetically → CHUNK_FILES listmatched_tags[] — store as TAGS for Phase 2 principle discoveryacceptance_criteria[] for cross-cutting verification in Phase 4After Phase 2, process each chunk in CHUNK_FILES sequentially in Phase 3:
design_references[] with type: "file", Read the screenshot file now. Study layout, spacing, colors, element sizes, and composition before writing code. For type: "inline", read the embedded content as layout/structure reference.directive as the instruction, action + file as the target, acceptance_criteria as verification checklisttest_cases[], implement each test case exactly as described. Each entry has type (unit/ui/integration) and description with given/when/expect. Do not invent additional tests, do not skip any.2.1 Determine matched tags by mode:
implement mode: use TAGS from Phase 1.2
refactor mode: call mcp__plugin_solid-coder_docs__get_candidate_tags(), then scan source files for imports/patterns matching the returned tags
code mode (default): no tags (load all principles)
2.2 Call mcp__plugin_solid-coder_docs__load_rules with mode: "code" and matched_tags: [tags from 2.1] (omit matched_tags if no tags). Apply the returned rules throughout Phase 3.
Apply every constraint from the Phase 2 summary to every line of code. Do NOT defer to the self-check — violations must be prevented, not detected after the fact.
3.1 For each plan item (in dependency order),
directive and acceptance_criteria. Print it out 3.2 For each plan item with design_references: re-read the design screenshots and verify your code matches the layout, spacing, colors, and element sizes before moving to the next item.
3.3 After creating or extracting any new type, static function, helpers, use skill solid-coder:create-type on the file(s) to enforce naming conventions, file organization, and /** solid-... */ frontmatter. Pass --spec {spec_number} if spec_number is present in the loaded plan.
After writing all code, verify your output against every loaded rule:
rule.md's metrics against your coderule.md and check againdesign_references, verify the implemented code matches the provided designs. For type: "file" references, read the file (screenshots, mockups, schemas). For type: "inline" references, use the embedded content (mermaid diagrams, ASCII mockups). Check layout structure, component hierarchy, spacing, naming, and behavior match the design. If any mismatch is found, fix it inline.
acceptance_criteria, verify the implemented code satisfies every criterion. If any is not met, fix it inline.acceptance_criteria[], verify each one is satisfied across the full set of files created/modified. If any is not met, fix it inline.
Do NOT spawn another agent. Do NOT produce intermediate artifacts. Fix problems in place.STOP. Before running any build command: have you finished writing ALL files for every plan item in this chunk?
Do not interleave write → build → fix → write → build. Write everything first, then build once. One build surfaces all errors together.
Use mcp__plugin_solid-coder_apple-build__build, __lint, and __test. Always pass project_path: CURRENT_PROJECT.
mcp__plugin_solid-coder_apple-build__build. Fix all errors and warnings. Repeat until clean.mcp__plugin_solid-coder_apple-build__lint. Fix all violations. Repeat until clean.mcp__plugin_solid-coder_apple-build__test, skip_ui_tests: true, for the component you modified. Fix and re-run until green.mcp__plugin_solid-coder_apple-build__test, skip_ui_tests: true, full target. Fix and re-run until green.mcp__plugin_solid-coder_apple-build__test, skip_unit_tests: true, only_testing: ["UITestTarget/SuiteForComponent"]. If no UI tests exist for your component → skip to 5.6. If broken: call mcp__plugin_solid-coder_apple-build__get_test_failures for activity logs. Fix and re-run until green.mcp__plugin_solid-coder_apple-build__test, skip_unit_tests: true, full target. If no UI test suite exists → skip to 5.7. Fix and re-run until green.
Design patterns — whenever you identify, apply, or reference a design pattern (facade, adapter, decorator, strategy, factory, builder, etc.) call mcp__plugin_solid-coder_docs__load_pattern with the pattern name before writing code that uses it. Apply the returned contract.
Search before creating — before creating any new type, protocol, or abstraction, call mcp__plugin_solid-coder_pipeline__search_codebase with sources_dir set to the project root and tags containing the type name + keywords from its responsibility. If a match is returned, read the file and reuse or adapt it. Only create if no relevant match exists.
Extraction — when splitting a type along responsibility boundaries: each responsibility becomes its own type with protocol-typed dependencies injected via init; no sealed variation points; the original type becomes a facade/coordinator.
File organization — protocol + one implementation → same file named after the implementation; additional conformers → separate files named after the conformer; small helpers (<10 lines, or private/fileprivate) → stay inline; new files go in the same directory as the source file; group files sharing a domain prefix into a subdirectory.
Protocol design — every conformer must meaningfully implement every method (if a conformer would leave methods empty or crash, the protocol is too wide — split it); client code must not type-check against conformers (is, as?, as!) — if it does the abstraction is wrong.
rule.md and instructions.md files are the source of truth for what constitutes a violation and how to write and fix code. MUST be followed. Do not invent additional rulesmcp__plugin_solid-coder_pipeline__search_codebase before creating new protocols, wrappers, or abstractions — see Plan extension abovehead, tail, | head -N, or line limits on any command, script, or file read. Always read the full content.cat, head, tail, less, or any shell command to inspect source files — use the Read tool. Reading a file you just wrote via cat duplicates it in context through a separate channel and wastes tokens.