go-writing-code

Installation
SKILL.md

Go Writing Code

Quick reference for writing idiomatic, production-quality Go code. Each section summarizes the key rules — reference files provide full examples and edge cases.

Go Code Idioms

Naming

  • MixedCaps — Go uses MixedCaps or mixedCaps, never underscores. Exported names start with uppercase.
  • Short names for short scopesi for loop index, r for reader, ctx for context. Longer names for longer scopes.
  • Package names — Lowercase, single word, no underscores. The package name is part of the API: http.Client, not http.HTTPClient.
  • Interface names — Single-method interfaces use method name + er suffix: Reader, Writer, Stringer.
  • Acronyms — All caps: HTTPClient, userID, xmlParser.

Core Idioms

Related skills
Installs
3
GitHub Stars
2
First Seen
Mar 10, 2026