WHEN: User requests Go code work (implement, fix, add, refactor) or mentions @ldd in a Go project. Orchestrates complete workflow (Phases 1-5): design → test → implement → lint → fix → documentation. Auto-triggers parallel quality analysis and iterative fix loop until code is commit-ready.
Automates Go development from design to commit. Triggers on Go code requests or @ldd mentions, orchestrating tests, linting, and iterative fixes until code is commit-ready.
/plugin marketplace add buzzdan/ai-coding-rules/plugin install go-linter-driven-development@ai-coding-rulesThis skill is limited to using the following tools:
reference.mdReference: See reference.md for agent prompt templates, example reports, and output formats.
</objective>
<essential_principles> Auto-Pilot Behavior: This skill triggers automatically when Go code work is detected. After permission is granted, announce: "Using go-ldd workflow for this Go code work" and proceed to pre-flight check.
Trigger Conditions:
<quick_start> Immediate Action: Run Pre-Flight Check, then execute phases sequentially until commit-ready.
<pre_flight_check> ALWAYS RUN FIRST
<step name="confirm_intent"> Look for keywords: "implement", "ready", "execute", "do", "start", "continue", "next", "build", "create", "step 1", "task 2", or explicit "@linter-driven-development", "@ldd", "ldd" </step> <step name="verify_go_project"> Check that `go.mod` exists in the project root or parent directories. </step> <step name="find_commands"> **Search locations** (in order): 1. Project docs: `README.md`, `CLAUDE.md`, `agents.md` 2. Build configs: `Makefile`, `Taskfile.yaml`, `.golangci.yaml` 3. Git repository root for workspace-level commandsExtract commands:
go test, make test, task testgolangci-lint run --fix, make lint, task lintwithfixgo test ./... and golangci-lint run --fix
</step>
<decision_tree> <decision condition="All conditions met" action="Announce 'Engaging autopilot mode for [description]' → Phase 1" /> <decision condition="Unclear intent" action="Ask for confirmation" /> <decision condition="No plan found" action="Suggest creating plan first (offer @code-designing)" /> <decision condition="Not Go project" action="Explain limitation" /> </decision_tree> </pre_flight_check>
<phase name="1" title="Implementation Foundation"> **Design Architecture** (if new types/functions needed): - Invoke @code-designing skill - Output: Type design plan with self-validating domain typesWrite Tests First:
Implement Code:
The agent automatically:
<test_focus_mode> Loop until tests pass:
Max 10 iterations. If stuck, ask user for guidance. </test_focus_mode> </phase>
<phase name="3" title="Iterative Fix Loop"> **For each prioritized fix** (from agent's report):Apply Fix:
Verify Fix (Incremental Mode):
mode: incrementalreference.md → "Agent Prompt Templates" for promptRoute Based on Status:
TEST_FAILURE → Enter Test Focus ModeCLEAN_STATE → Break loop, go to Phase 4ISSUES_FOUND → Continue to next fix (or retry if no progress)Safety Limits:
Loop until agent returns CLEAN_STATE. </phase>
<phase name="4" title="Documentation"> Invoke @documentation skill: 1. Add/update package-level godoc 2. Add/update type and function documentation (WHY not WHAT) 3. Add godoc testable examples (Example_* functions) 4. If last plan step → add feature documentation to docs/Verify: Run go doc -all ./... and ensure examples compile.
</phase>
Present user with options:
<workflow_control> <control aspect="Phases" behavior="Sequential: 1 → 2 → 3 → 4 → 5" /> <control aspect="Routing" behavior="Agent status determines path" /> <control aspect="Parallelism" behavior="Phase 2 runs 3 tools simultaneously" /> <control aspect="Incremental" behavior="After first run, agent analyzes only changed files" /> </workflow_control>
<integration> **Skills invoked**: - @code-designing (Phase 1, if needed) - @testing (Phase 1) - @refactoring (Phase 3) - @documentation (Phase 4)Agents invoked:
go-linter-driven-development:quality-analyzer (Phase 2 and Phase 3 verification)
go-linter-driven-development:go-code-reviewer for design analysisAfter committing:
<success_criteria> Workflow is complete when ALL of the following are true:
CLEAN_STATE:
This skill should be used when the user asks to "create a slash command", "add a command", "write a custom command", "define command arguments", "use command frontmatter", "organize commands", "create command with file references", "interactive command", "use AskUserQuestion in command", or needs guidance on slash command structure, YAML frontmatter fields, dynamic arguments, bash execution in commands, user interaction patterns, or command development best practices for Claude Code.
This skill should be used when the user asks to "create an agent", "add an agent", "write a subagent", "agent frontmatter", "when to use description", "agent examples", "agent tools", "agent colors", "autonomous agent", or needs guidance on agent structure, system prompts, triggering conditions, or agent development best practices for Claude Code plugins.
This skill should be used when the user asks to "create a hook", "add a PreToolUse/PostToolUse/Stop hook", "validate tool use", "implement prompt-based hooks", "use ${CLAUDE_PLUGIN_ROOT}", "set up event-driven automation", "block dangerous commands", or mentions hook events (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification). Provides comprehensive guidance for creating and implementing Claude Code plugin hooks with focus on advanced prompt-based hooks API.