golangci-linting

Automate golangci-lint v2 linting and quality checks for Go projects.

23|2|Updated Jun 9, 2025
One-click install
npx skills add https://github.com/kaptinlin/gozod --skill golangci-linting
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: golangci-linting
Source: https://github.com/kaptinlin/gozod/tree/main/.agents/skills/golangci-linting
Command: npx skills add https://github.com/kaptinlin/gozod --skill golangci-linting

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Go linting setup and enforcement for Go projects using golangci-lint v2, simplifying configuration and maintenance.

Core Features & Use Cases

  • Pin and install a specific golangci-lint version via .golangci.version and local Makefile integration.
  • Configure and run v2 linting across multi-module repos, including CI workflows.
  • Provide a reusable linting workflow covering lint, fmt, vet, and tidy checks across modules.

Quick Start

Run the lint workflow to validate your codebase with the local targets.

Frequently Asked Questions about golangci-linting

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

FAQPage Schema
How do I set up golangci-lint v2 in a multi-module Go repository?

To set up golangci-lint v2 in a multi-module Go repository, you need a pinned version in .golangci.version, a v2 configuration in .golangci.yml, and Taskfile or Makefile targets to automate lint, tidy, fmt, and vet tasks across modules.

What is the best way to automate Go static analysis in CI workflows?

The best way to automate Go static analysis in CI workflows is by using golangci-lint v2. This requires configuring .golangci.yml and integrating Makefile targets to enforce style and ensure build cleanliness across your modules.

Does golangci-lint v2 work with both Makefile and Taskfile for local development?

Yes, golangci-lint v2 works with both Makefile and Taskfile for local development. You can define reusable targets to automate lint, fmt, vet, and tidy checks, ensuring consistent quality enforcement locally before running CI workflows.

Why do I need a .golangci.version file for my Go project?

You need a .golangci.version file to pin and install a specific golangci-lint version. This ensures consistent static analysis, linting behavior, and style enforcement across local development environments and CI workflows.

Can I run fmt, vet, and tidy checks alongside linting in golangci-lint?

Yes, you can run fmt, vet, and tidy checks alongside linting. By configuring Taskfile or Makefile targets, you can provide a reusable workflow that detects and fixes lint issues while enforcing build cleanliness across all modules.