Skip to content
Back to search

golang-skills

MarketplaceWorks with Claude CodeGitHub

AI Agent Skills for idiomatic, production-ready Go code, distilled from Google, Uber, Community

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/cxuu-golang-skills/badge.svg)](/listings/cxuu-golang-skills)

HTML

<a href="/listings/cxuu-golang-skills"><img src="/api/listings/cxuu-golang-skills/badge.svg" alt="findsafeskills safety rating" /></a>

Install

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Using npx skills (Recommended)

The easiest way to install across **any** AI coding agent. Supports Cursor, Codex, OpenCode, Cline, GitHub Copilot, Windsurf, Roo Code, and [25+ more agents](https://github.com/vercel-labs/skills#supported-agents).

npx skills add cxuu/golang-skills --all

Claude Code

# Add the marketplace (one time)
/plugin marketplace add cxuu/golang-skills

# Install the skills
/plugin install golang-skills@cxuu-golang-skills

Cursor (Native Remote Rule)

1. Open **Cursor Settings** (Cmd+Shift+J on Mac, Ctrl+Shift+J on Windows/Linux) 2. Navigate to **Rules** → **Add Rule** → **Remote Rule (Github)** 3. Enter: `https://github.com/cxuu/golang-skills`

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 18 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. {
  2. "name": "golang-skills",
  3. "owner": {
  4. "name": "cxuu"
  5. },
  6. "metadata": {
  7. "description": "20 modular skills for idiomatic Go, derived from Effective Go, Google Go Style Guide, Uber Go Style Guide, and Go Wiki CodeReviewComments. Backed by 48 reference files, 8 automation scripts (all with --json, --limit, --force), and 4 asset templates.",
  8. "version": "1.8.0"
  9. },
  10. "plugins": [
  11. {
  12. "name": "golang-skills",
  13. "source": "./",
  14. "description": "20 Go skills (each under 225 lines) with progressive disclosure, conditional cross-references, and bundled automation. Covers style, naming, error handling, testing, concurrency, generics, logging, documentation, performance, and more.",
  15. "version": "1.8.0"
  16. }
  17. ]
  18. }
README.md · README · 144 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Agent Skills For Go
  2. AI [Agent Skills](https://agentskills.io/) for writing idiomatic,
  3. production-quality Go code. 20 modular skills teach AI coding assistants Go
  4. best practices derived from:
  5. - [Google Go Style Guide](https://google.github.io/styleguide/go/)
  6. - [Effective Go](https://go.dev/doc/effective_go)
  7. - [Uber Go Style Guide](https://github.com/uber-go/guide/blob/master/style.md)
  8. - [Go Wiki CodeReviewComments](https://github.com/golang/go/wiki/CodeReviewComments)
  9. Skills are tuned following
  10. [agentskills.io best practices](https://agentskills.io/skill-creation/best-practices):
  11. content the agent already knows is omitted, procedural decision trees guide
  12. multi-step tasks, 48 reference files load on demand via progressive disclosure,
  13. 8 bundled scripts automate common checks, and 4 asset templates ensure
  14. consistent output.
  15. ## Skills Included
  16. | Skill | Description |
  17. |-------|-------------|
  18. | **go-code-review** | Systematic checklist for reviewing Go code and PR submissions |
  19. | **go-concurrency** | Goroutine lifecycle, channels, mutexes, parallelization, thread-safety |
  20. | **go-context** | Context.Context placement, cancellation, deadlines, request-scoped data |
  21. | **go-control-flow** | Idiomatic conditionals, loops, switch/break behavior, guard clauses |
  22. | **go-data-structures** | Slices, maps, arrays — allocation with new vs make, append, copying |
  23. | **go-declarations** | Variable/const/type declarations, var vs :=, iota enums, shadowing |
  24. | **go-defensive** | API boundary hardening, defer cleanup, Must functions, time handling |
  25. | **go-documentation** | Doc comments, package docs, godoc formatting, runnable examples |
  26. | **go-error-handling** | Error strategy decisions, wrapping (%v vs %w), sentinels, logging patterns |
  27. | **go-functional-options** | Functional options pattern for constructors with optional config |
  28. | **go-functions** | Function ordering, signature formatting, Printf verbs, Stringer interface |
  29. | **go-generics** | When to use generics, constraints, common pitfalls, type aliases |
  30. | **go-interfaces** | Interface design, abstractions, embedding, "accept interfaces return structs" |
  31. | **go-linting** | Linters, golangci-lint setup, nolint directives, CI/CD integration |
  32. | **go-logging** | Structured logging with slog, log levels, request-scoped context, migration |
  33. | **go-naming** | Naming decision flow for packages, types, functions, variables, receivers |
  34. | **go-packages** | Package organization, imports, package size, CLI/flag patterns |
  35. | **go-performance** | String optimization, capacity hints, benchmarking, strconv over fmt |
  36. | **go-style-core** | Formatting, nesting reduction, style principles, fallback style guide |
  37. | **go-testing** | Table-driven tests, subtests, test helpers, assertions, test organization |
  38. ## Bundled Scripts
  39. 8 scripts automate common Go checks. All support `--help`, `--json` for
  40. structured output, and meaningful exit codes (0 = clean, 1 = issues found,
  41. 2 = error). Analysis scripts support `--limit` to cap output size, and
  42. destructive scripts require `--force` to overwrite existing files.
  43. | Script | Skill | Purpose |
  44. |--------|-------|---------|
  45. | `pre-review.sh` | go-code-review | Run gofmt + go vet + golangci-lint before review |
  46. | `check-naming.sh` | go-naming | Detect SCREAMING_SNAKE, Get-prefixed getters, bad package names |
  47. | `check-docs.sh` | go-documentation | Find exported symbols missing doc comments |
  48. | `check-errors.sh` | go-error-handling | Catch bare returns, string comparison on errors, log-and-return |
  49. | `check-interface-compliance.sh` | go-interfaces | Find interfaces missing compile-time verification |
  50. | `bench-compare.sh` | go-performance | Run benchmarks with optional benchstat comparison |
  51. | `setup-lint.sh` | go-linting | Generate .golangci.yml with recommended linters |
  52. | `gen-table-test.sh` | go-testing | Scaffold a table-driven test file |
  53. ## Quick Install
  54. ### Using npx skills (Recommended)
  55. The easiest way to install across **any** AI coding agent. Supports Cursor,
  56. Codex, OpenCode, Cline, GitHub Copilot, Windsurf, Roo Code, and [25+ more
  57. agents](https://github.com/vercel-labs/skills#supported-agents).
  58. ```bash
  59. npx skills add cxuu/golang-skills --all
  60. ```
  61. ### Claude Code
  62. ```bash
  63. # Add the marketplace (one time)
  64. /plugin marketplace add cxuu/golang-skills
  65. # Install the skills
  66. /plugin install golang-skills@cxuu-golang-skills
  67. ```
  68. ### Cursor (Native Remote Rule)
  69. 1. Open **Cursor Settings** (Cmd+Shift+J on Mac, Ctrl+Shift+J on Windows/Linux)
  70. 2. Navigate to **Rules** → **Add Rule** → **Remote Rule (Github)**
  71. 3. Enter: `https://github.com/cxuu/golang-skills`
  72. ## How It Works
  73. These skills follow the [Agent Skills open standard](https://agentskills.io/),
  74. which works across multiple AI coding tools. When you're writing Go code:
  75. 1. **Automatic activation**: The AI agent loads relevant skills based on context
  76. (e.g., `go-naming` when you're writing a new function)
  77. 2. **Procedural guidance**: Decision trees and step-by-step procedures for
  78. multi-step tasks like code review and error strategy selection
  79. 3. **Progressive disclosure**: Core rules load immediately; 48 reference files
  80. load on demand when specific situations arise
  81. 4. **Automation**: 8 bundled scripts handle repetitive checks so the agent
  82. focuses on higher-level guidance
  83. 5. **Conditional cross-references**: Skills link to each other with "when"
  84. conditions to avoid unnecessary context loading
  85. 6. **Rule ownership**: `docs/RULE_OWNERSHIP.md` keeps duplicated guidance out
  86. of non-owner skills
  87. ## Project Structure
  88. ```
  89. .
  90. ├── skills/
  91. │ └── go-*/
  92. │ ├── SKILL.md # Core rules (< 225 lines each)
  93. │ ├── references/ # Detailed guidance, loaded on demand
  94. │ ├── scripts/ # Automation scripts and helpers
  95. │ └── assets/ # Output templates (4 skills)
  96. ├── evals/
  97. │ ├── evals.json # Trigger and quality eval definitions
  98. │ ├── files/ # Sample Go files for quality evals
  99. │ └── fixtures/ # Test fixtures for script/eval coverage
  100. ├── docs/ # Repository maintenance notes
  101. ├── .github/workflows/ # CI validation
  102. └── source/ # Original style guide sources
  103. ```
  104. ## Provenance and Compatibility
  105. Bundled upstream source snapshots live under `source/`. Each source file keeps
  106. its own inline provenance header, and [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md)
  107. summarizes the source path, upstream project, URL, license, and copyright at the
  108. repository level.
  109. Go-version-sensitive guidance is tracked in [COMPATIBILITY.md](COMPATIBILITY.md).
  110. When a skill recommends a standard-library API that depends on a specific Go
  111. release, the guidance should name the minimum Go version and include an older
  112. fallback where that helps users on maintained but older toolchains.
  113. ## License
  114. Project-authored skill files, scripts, assets, docs, and evals are licensed
  115. under the Apache License, Version 2.0. See [LICENSE](LICENSE) for details.
  116. Bundled upstream snapshots under `source/` retain their upstream licenses; see
  117. [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md).

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.