go-coding-standards

go-coding-standards is a skill for Claude Code, Codex from williamzujkowski/standards. It costs 44 tokens per session (2,746 once invoked), scanned A, original, MIT.

A set of conventions for writing Go code, including error handling, concurrent work, formatting, documentation, and tests. Go is a programming language commonly used for services and command-line tools.

In plain words
What is it for?
Use it when building or reviewing Go projects. It covers formatting, dependency files, linting, error handling, table-driven tests, benchmarks, and secure defaults.
Why use it?
It reduces inconsistent code, missed errors, unclear names, and fragile concurrent behavior. It gives a shared checklist for keeping Go projects easier to read and maintain.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is go build -o app ./cmd/app.

Good fit Use it when building or reviewing Go projects. It covers formatting, dependency files, linting, error handling, table-driven tests, benchmarks, and secure defaults.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/williamzujkowski/standards
agentmods
npx agentmods add skills/williamzujkowski/standards/go

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for go-coding-standards

README.md
[![agentmods](https://agentmods.dev/badge/skills/williamzujkowski/standards/go/github.svg)](https://agentmods.dev/skills/williamzujkowski/standards/go)
Your own site
<a href="https://agentmods.dev/skills/williamzujkowski/standards/go"><img src="https://agentmods.dev/badge/skills/williamzujkowski/standards/go/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for go-coding-standards

Your own site · 80×15
<a href="https://agentmods.dev/skills/williamzujkowski/standards/go"><img src="https://agentmods.dev/badge/skills/williamzujkowski/standards/go.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 44 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,746 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00044 $0.02746
Opus 5.5 $0.00018 $0.01098
Sonnet 5.5 $0.00009 $0.00549
Haiku 4.5 $0.00004 $0.00275

Measured yesterday against content hash 49d69e0a431d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-30, from the pricing page.

Security

Grade A, and why

go-coding-standards scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/coding-standards/go/SKILL.md · 470 lines

How it starts

The opening of the file, as written. The whole thing — 470 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Go Coding Standards

Quick Navigation: Level 1: Quick Start (5 min) → Level 2: Implementation (30 min) → Level 3: Mastery (Extended)


Level 1: Quick Start (<2,000 tokens, 5 minutes)

Core Principles

  1. Idiomatic Go: Write code that follows Go idioms - simple, clear, and effective
  2. Explicit Errors: Return errors explicitly, handle them properly, no exceptions
  3. Interfaces: Accept interfaces, return concrete types
  4. Concurrency: Goroutines and channels for concurrent operations
  5. Testing: Table-driven tests with >80% coverage

Essential Checklist

  • Formatting: Code formatted with gofmt, imports organized with goimports
  • Naming: Follow Go conventions (MixedCaps, camelCase, short names in limited scope)
  • Error Handling: All errors checked and wrapped with context
  • Testing: _test.go files with table-driven tests, benchmarks
  • Documentation: Package and exported function documentation
  • Modules: go.mod with semantic versioning, tidy dependencies
  • Linting: Pass golangci-lint with strict configuration
  • Security: Input validation, no hardcoded secrets, secure defaults

Quick Example

// Package auth provides user authentication services.
package auth

import (
	"context"
	"errors"
	"fmt"
)

var (
	// ErrInvalidCredentials indicates authentication failure.
	ErrInvalidCredentials = errors.New("invalid credentials")
	// ErrUserNotFound indicates user does not exist.
	ErrUserNotFound = errors.New("user not found")
)

// User represents an authenticated user.
type User struct {
	ID       string
	Username string
	Email    string
}

// Repository defines user storage operations.
type Repository interface {
	FindByUsername(ctx context.Context, username string) (*User, error)
	VerifyPassword(ctx context.Context, userID, password string) bool
}

// Service handles authentication operations.
type Service struct {
	repo Repository
}

// NewService creates a new authentication service.
func NewService(repo Repository) *Service {
	return &Service{repo: repo}
}

// Authenticate verifies credentials and returns the authenticated user.
//
// Returns ErrInvalidCredentials if authentication fails,
// ErrUserNotFound if user doesn't exist, or wrapped errors for other failures.
func (s *Service) Authenticate(ctx context.Context, username, password string) (*User, error) {
	if username == "" || password == "" {
		return nil, fmt.Errorf("username and password required")
	}

	user, err := s.repo.FindByUsername(ctx, username)
	if err != nil {
		if errors.Is(err, ErrUserNotFound) {
			return nil, ErrInvalidCredentials // Don't reveal user existence
		}
		return nil, fmt.Errorf("find user: %w", err)
	}

	if !s.repo.VerifyPassword(ctx, user.ID, password) {
		return nil, ErrInvalidCredentials
	}

	return user, nil
}

Read the full file on GitHub · 470 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 470 lines · 44 tokens per session scan A 49d69e0a431d

Subscribe to this mod's changes

go-coding-standards is a skill published in the GitHub repository williamzujkowski/standards (18 stars, last pushed 1mo ago), licensed MIT. It adds 44 tokens to every session and 2,746 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-29.

Related

Other skills, from other repositories

timeouts-and-async

Make Ginkgo specs interruptible and test asynchronous behavior — SpecContext/context.Context cancellable nodes, NodeTimeout/SpecTimeout/GracePeriod, the --timeout flag, Abort and SIGINT behavior, Gomega Eventually/Consistently (the func(g Gomega) form, .WithContext), and the defer GinkgoRecover() rule for goroutines.…

onsi/ginkgo · 106 tokens

setup

Wire Ginkgo into a Go package — install the ginkgo CLI and Ginkgo+Gomega, ginkgo bootstrap to generate the suitetest.go (TestXxx/RegisterFailHandler(Fail)/RunSpecs), the package xxxtest convention, dot-import alternatives (aliased import, dsl/ subpackages, --nodot), ginkgo generate, and testing.T interop via…

onsi/ginkgo · 118 tokens

overview

The Ginkgo mental model for writing Go tests — the one idea that explains everything (Ginkgo builds a spec tree at construction time, then runs it) and its consequences for how you write specs, plus spec independence and the node taxonomy. Use this first when you start working with Ginkgo in a project, or to decide…

onsi/ginkgo · 84 tokens

assertions

Write correct synchronous Gomega assertions — Expect/Ω notation, the To/NotTo/ToNot/Should/ShouldNot equivalences, the multi-return error idiom, Succeed vs HaveOccurred, the .Error() chaining form, annotating assertions (format-string and func()string), tuning failure output via the format subpackage…

onsi/gomega · 145 tokens

gstruct

Deep, partial matching of nested structs, slices, maps, and pointers with gstruct — MatchAllFields/MatchFields/Fields, MatchAllElements/MatchElements/Elements (idFn), MatchAllKeys/MatchKeys/Keys, PointTo, and the IgnoreExtras/IgnoreMissing/IgnoreUnexportedExtras/AllowDuplicates options, plus Ignore()/Reject(). Use…

onsi/gomega · 104 tokens

golang-testing

Production-ready Golang tests — table-driven tests, testify suites and mocks, parallel tests, fuzzing, fixtures, goroutine leak detection with goleak, snapshot testing, code coverage, integration tests, idiomatic test naming. Use when writing or reviewing Go tests, choosing a testing approach, setting up Go test CI…

samber/cc-skills-golang · 115 tokens