claudecodex

golang

Go code-quality skills covering errors, concurrency, interfaces, generics, testing, and modules

0 on GitHubby Qv0.1.0MITupdated 2 months agoDeveloper Tools
/

Plugin golang from marketplace golang-skills-marketplace in ctoth/golang-skills-plugin. Commands read from the repo's manifest — 1 month ago.

What it installs

Skills (25)

  • go-channels-select

    Guides Go channel mechanics — declare directionality in signatures (chan less than - send-only, less than -chan receive-only), let only the sender close and only when sends are done (closing is a broadcast, not cleanup), read the comma-ok / range-ends-on-close idiom so a closed channel's zero value

  • go-concurrency-goroutines

    Guides goroutine lifetime and ownership — never start a goroutine you can't stop, give every goroutine a defined exit (context cancellation, a closed channel, or bounded work), avoid the blocked-forever leak, use sync.WaitGroup correctly (Add before the go, or wg.Go in 1.25) and golang.org/x/sync/er

  • go-context

    Guides Go context.Context discipline — pass it as the first parameter named ctx and never store it in a struct, derive children with WithCancel/WithTimeout/WithDeadline and ALWAYS defer cancel() (go vet's lostcancel flags a missing one), check ctx.Done()/ctx.Err() in loops and before expensive work,

  • go-defer-panic-recover

    Guides Go's defer, panic, and recover — the LIFO ordering and arguments-evaluated-at-the-defer-statement semantics, why defer is near-free since open-coded defers (so don't avoid it except in tight loops), the loop-defer handle-leak pitfall, panic only for programmer bugs and unrecoverable states (n

  • go-error-handling

    Guides Go error handling as values — wrap with fmt.Errorf and %w to preserve the chain, inspect with errors.Is (sentinel) and errors.As / errors.AsType (typed) instead of string-matching, choose sentinel vs custom error types and when they become API, combine with errors.Join, write lowercase un-pun

  • go-generics

    Guides Go generics restraint and constraint design — reach for a type parameter only when you would otherwise write the exact same code for multiple types (a container, or an algorithm over a slice/map/channel element type like map/filter/reduce), never when you only call a method on the value (that

  • go-idiomatic-discipline

    Guides core Go authoring discipline along two axes — handle errors honestly and stop fighting the language on the floor (no discarded errors, no panic for ordinary failure, no Java/Python-in-Go), and don't over-abstract or out-clever it on the ceiling (no interface-per-struct, no premature generics,

  • go-interfaces

    Guides Go interface design and the typed-nil-error gotcha — accept interfaces and return concrete structs, keep interfaces small (1–3 methods, `-er` names), define them on the consumer side not the producer, avoid `any`/`interface{}` as a parameter type, compose with embedding, and never return a co

  • go-iterators-rangefunc

    Guides writing and consuming Go push iterators (range-over-func, Go 1.23) — an iter.Seq[V] is func(yield func(V) bool), the iterator calls yield per element and MUST stop calling it the moment yield returns false (the central bug is ignoring that bool — the runtime panics on a yield call after it re

  • go-json

    Guides encoding/json correctly — only exported fields marshal (a lowercase field is silently dropped), struct tags (`json:"name,omitempty"`, `json:"-"`, `,string`), the omitempty-vs-omitzero (Go 1.24) trap where omitempty does NOT drop a zero struct or time.Time, decoding into interface{} yielding m

  • go-modules-and-versioning

    Guides Go module mechanics and versioning — author and edit go.mod/go.sum through the go command (never by hand), understand that MVS selects the minimum version that satisfies all requirements (not the latest), put /v2 in both the module path and the import path for v2+ (semantic import versioning)

  • go-naming-and-style

    Guides how Go reads to a human across two themes — identifier and structural naming (MixedCaps/mixedCaps never under_scores, initialisms kept as one case unit like URL/ID/HTTP, no Get prefix on getters, single-method interfaces get -er names, short scope-proportional variable and 1–2-letter receiver

  • go-performance

    Guides Go performance work as a measure-first discipline — never optimize from intuition; profile or benchmark first, then optimize only what the data proves is hot, without sacrificing clarity for unmeasured speed. Covers benchmarking with go test -bench -benchmem and comparing runs with benchstat

  • go-project-layout

    Guides how a Go module is organized into directories and packages — start flat (a single package at the module root is fine; don't build a deep tree prematurely), put each binary behind cmd/name/main.go and keep main thin (parse flags, wire dependencies, delegate to importable packages so the logic

  • go-race-and-memory-model

    Guides what a data race actually is in Go and how to detect it — a data race (two goroutines touch the same memory concurrently, at least one writing, with no happens-before edge) is undefined behavior, not a stale read; happens-before comes only from channels, mutexes, Once, WaitGroup, and atomics,

  • go-slices-and-maps

    Guides Go slice and map data operations and the slices/maps stdlib packages — a slice is a view (pointer, len, cap) over a backing array, so subslices alias and append conditionally mutates a caller's shared array (the #1 slice bug); use a 3-index slice or slices.Clone/Clip to break aliasing and bou

  • go-slog-logging

    Guides Go logging with log/slog (Go 1.21+) — the stdlib STRUCTURED logger — over fmt.Println / log.Printf debugging and ad-hoc string logs. Prefer typed attrs (slog.String/Int) or LogAttrs to the key-value variadic form, which silently emits !BADKEY on an odd argument count; set a minimum level and

  • go-strings-bytes-runes

    Guides Go string handling as what a string actually is — an immutable, read-only slice of UTF-8 bytes where indexing yields a byte (not a character), len is a byte count (not a rune count), for range decodes runes while an indexed for walks bytes, []byte/[]rune conversions copy, string(intValue) is

  • go-sync-primitives

    Guides Go's shared-memory synchronization toolkit — a zero-value sync.Mutex/RWMutex is ready with no constructor and must NEVER be copied after first use (passing a struct-with-Mutex by value copies the lock; go vet's copylocks catches it), keep critical sections small with defer Unlock right after

  • go-testing-advanced

    Guides Go's advanced testing techniques — native fuzzing (FuzzXxx, f.Add seed corpus, f.Fuzz property body, the testdata/fuzz corpus, go test -fuzz); benchmarks with the Go 1.24 `for b.Loop()` loop that replaces the error-prone `for i := 0; i less than b.N; i++`, plus b.ReportAllocs, b.ResetTimer, b

  • go-testing-tabledriven

    Guides Go test structure — a slice of named struct cases looped through t.Run so every case is an isolated, individually-runnable subtest; t.Helper in assertion helpers so failures point at the caller; t.Cleanup (LIFO) over defer for teardown; t.Parallel for concurrency (and the Go 1.22 loop-var cha

  • go-time

    Guides the time package correctly — never compare time.Time with == (it compares the wall instant AND the monotonic reading AND the Location, so two values for the same instant can be unequal); use t.Equal/t.Before/t.After. Reference-layout formatting where the magic constant is the date "Mon Jan 2

  • go-tooling-and-static-analysis

    Guides the Go detection layer — the CI gate that catches the rules the authoring skills teach. gofmt/gofumpt for canonical formatting; go vet for built-in correctness analyzers (printf, copylocks, lostcancel, loopclosure, stringintconv, waitgroup); staticcheck for deeper bug/simplification/style che

  • go-version-feature-map

    The consolidated Go 1.21→1.26 feature reference and modernization rule — which idiom is available given the module's `go` directive, and prefer the modern builtin/stdlib form over the stale hand-rolled one. The `go` line gates which language features compile (range-over-func needs `go 1.23`, per-ite

  • go-zero-values-and-construction

    Guides how a Go value comes into existence honestly — design types whose zero value is already useful (a zero sync.Mutex, bytes.Buffer, or nil slice just works) so you don't write a New that only zeroes fields; use keyed composite literals over positional ones; pick new vs &T{} vs make correctly; re

View source on GitHub

More from ctoth/golang-skills-plugin

All 2 plugins →

Go performance skills covering benchmarks, profiles, traces, allocation, GC, layout, I/O, and contention

34 skills

0

Similar plugins

superpowers

claudecodex

Core skills library for Claude Code: TDD, debugging, collaboration patterns, and proven techniques

15 skills · hooks

obra/superpowers 316,836

Scaffold, validate, and publish new Claude Code plugins with proper structure

3 skills · 1 command · 1 agent

ruvnet/ruflo 81,589

context7

claudecodex

Up-to-date documentation lookup. Pull version-specific documentation and code examples directly from source repositories into your coding agent's context.

1 MCP server

upstash/context7 64,709

Use Alibaba Open Code Review from local Codex.

2 skills

alibaba/open-code-review 50,068

slidev

claude

Claude Code skill for creating and presenting Slidev slidedecks

1 skill

slidevjs/slidev 49,452

gitnexus

claudecodex

Code intelligence powered by a knowledge graph. Provides execution flow tracing, blast radius analysis, and augmented search across your codebase.

12 skills · 1 MCP server · hooks

abhigyanpatwari/GitNexus 48,482

Maintain golang?

This page updates itself from your repo. Add the badge to your README, or get it Featured to pin it above the organic results with a followed link to your site.

claude & codex plugins2 plugins