golang-code-style

Enforce Golang coding standards by analyzing code with gofmt, gofumpt, goimports, gocritic, revive, and wsl_v5.

Updated May 30, 2026
One-click install
npx skills add https://github.com/ozan-fn/mqtt-capture --skill golang-code-style-ozan-fn
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: golang-code-style
Source: https://github.com/ozan-fn/mqtt-capture/tree/main/.agents/skills/golang-code-style
Command: npx skills add https://github.com/ozan-fn/mqtt-capture --skill golang-code-style-ozan-fn

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires gofmt, gofumpt, goimports, gocritic, revive, wsl_v5, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill ensures consistent and high-quality code in Golang projects by enforcing coding standards, best practices, and style conventions.

Core Features & Use Cases

  • Code Style Enforcement: Checks for adherence to Golang style guidelines, including line length, variable declarations, control flow, and function design.
  • Automated Code Review: Identifies and suggests improvements for readability, maintainability, and performance.
  • Use Case: Use this Skill to review and refactor your Golang codebase, ensuring it meets the coding standards of your organization or project.

Quick Start

Run the golang-code-style skill on your Golang codebase to enforce coding standards and best practices.

Frequently Asked Questions about golang-code-style

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce Golang coding standards and best practices in my project?

You can enforce Golang coding standards by running automated linting and formatting checks that analyze code for readability, maintainability, and performance. This identifies style violations and suggests improvements for function design and control flow.

What is the best way to automate Golang code review for style and readability?

Automated Golang code review uses linters like revive and gocritic to check variable declarations and style conventions. This automatically identifies deviations from established guidelines and suggests refactoring improvements.

Do I need gofmt and goimports to check Golang style guidelines?

Yes, enforcing Golang style guidelines requires gofmt and goimports for formatting, alongside gofumpt, gocritic, revive, and wsl_v5. These dependencies provide the necessary formatting and linting rules to analyze your codebase.

How does linting with gocritic and revive improve Golang code maintainability?

Linting with gocritic and revive improves Golang maintainability by detecting complex control flows and non-idiomatic patterns. It enforces best practices automatically, suggesting refactoring changes that enhance overall code quality.

Can I use this approach to refactor an existing Golang codebase for performance?

Yes, you can review and refactor an existing Golang codebase to meet coding standards. The analysis targets performance, readability, and maintainability, applying style guidelines to update and standardize your code.