Skip to main content

/go-build Command

This command invokes the go-build-resolver agent to incrementally fix Go build errors with minimal changes.

What This Command Does

  1. Run Diagnostics: Execute go build, go vet, staticcheck
  2. Parse Errors: Group by file and sort by severity
  3. Fix Incrementally: One error at a time
  4. Verify Each Fix: Re-run build after each change
  5. Report Summary: Show what was fixed and what remains

When to Use

Use /go-build when:
  • go build ./... fails with errors
  • go vet ./... reports issues
  • golangci-lint run shows warnings
  • Module dependencies are broken
  • After pulling changes that break the build

Diagnostic Commands Run

Command Syntax

No arguments required - automatically detects and fixes Go build errors.

Common Errors Fixed

Stop Conditions

The agent will stop and report if:
  • Same error persists after 3 attempts
  • Fix introduces more errors
  • Requires architectural changes
  • Missing external dependencies
  • Agent: agents/go-build-resolver.md
  • Skill: skills/golang-patterns/
  • Commands: /go-test, /go-review, /verify