language-go
Go language patterns and best practices. Use when language go guidance is required.
When & Why to Use This Skill
The language-go skill is a specialized development assistant designed to enforce Go language patterns and best practices. It streamlines the Golang development lifecycle by integrating essential tools for code validation, automated linting, and testing, ensuring that your codebase remains idiomatic, performant, and maintainable.
Use Cases
- Automated Code Quality Audits: Utilize golangci-lint and go vet to perform deep static analysis, identifying potential bugs and style violations before they reach production.
- Continuous Testing and Validation: Execute go test and go build to verify code integrity, check test coverage, and ensure the project compiles correctly after changes.
- Dependency and Module Governance: Manage Go modules and project structures effectively using go mod to ensure dependency consistency and compliance.
- Idiomatic Pattern Enforcement: Receive guidance on Go-specific best practices to refactor legacy code into clean, idiomatic, and high-performance Golang patterns.
| name | language-go |
|---|---|
| description | Go language patterns and best practices. Use when language go guidance is required. |
Key Execution Capabilities
Code Validation
- Run
go buildfor compilation validation - Execute
golangci-lintfor comprehensive linting - Run tests with
go test - Validate module structure and dependencies
Tool Integration
- Use
golangci-lintfor multi-linter analysis - Leverage
go modfor dependency management - Apply
go fmtandgo vetfor formatting and validation - Execute
go testwith coverage for testing
Execution Context
- Process Go files from filesystem layer
- Generate structured reports with findings
- Create minimal, rule-compliant patches for violations
- Maintain separation between governance rules and execution tools
Error Handling
This skill provides execution-layer error handling for Go code analysis:
- Compilation errors or warnings
- Linting rule violations
- Missing dependencies or tools
- Test failures or coverage issues
Usage Notes
- Always delegate to governance rules for policy decisions
- Focus on concrete tool execution and result processing
- Provide deterministic, tool-first analysis results
- Maintain separation between rule definition and rule application