golang-code-style

This skill provides a comprehensive set of Go code style conventions focused on clarity, maintainability, and idiomatic patterns. It covers variable declarations, control flow, function design, file organization, and string handling, serving as a guide for human-judgment-based code reviews that complement automated linters.

33.3K
Installs
4
Use cases
5/10
Quality

Is golang-code-style safe to install?

Safe to install

Safe to install: our audit of golang-code-style's source files found 0 shell commands, 0 external URLs, file reads and writes (low risk). Every command and URL listed appears verbatim in the skill's source. The skill requires read access to project files to perform code reviews and style analysis.

How we audit skills: our security review methodology.

Who is this skill for?

Go developers and AI coding agents performing code reviews or writing new Go code.

What can you do with it?

  • Reviewing Go code for clarity and idiomatic style
  • Establishing project-wide coding standards
  • Refactoring complex functions for better readability
  • Parallelizing code style reviews across large codebases using sub-agents

How good is this skill?

Quality score: 5/10. The skill documentation is highly structured, provides clear code examples for both 'good' and 'bad' patterns, and explicitly defines its scope relative to other skills in the same suite.

What does the skill file contain?

SKILL.md
> **Community default.** A company skill that explicitly supersedes `samber/cc-skills-golang@golang-code-style` skill takes precedence.

# Go Code Style

Style rules that require human judgment — linters handle formatting, this skill handles clarity. For naming see `samber/cc-skills-golang@golang-naming` skill; for design patterns see `samber/cc-skills-golang@golang-design-patterns` skill; for struct/interface design see `samber/cc-skills-golang@golang-structs-interfaces` skill.

> "Clear is better than clever." — Go Proverbs

When ignoring a rule, add a comment to the code.

## Line Length & ...

Frequently asked questions

How does this skill differ from a linter?

Linters handle automated formatting and syntax checks, while this skill focuses on code clarity, design patterns, and style rules that require human judgment.

What should I do if I need to ignore a style rule?

Add a comment to the code to explain the deviation.

How should I handle long function signatures?

Put each parameter on its own line, or ideally, refactor the function to use an options struct to reduce the number of parameters.

Does this skill cover naming conventions?

No, naming conventions are covered by the samber/cc-skills-golang@golang-naming skill.

Data sourced from samber/cc-skills-golang on GitHub. Install counts from skills.sh. The summary and security audit are derived from the skill's source files: every command and URL listed appears verbatim in the source.

Related skills