Skills for Real Engineers. Straight from my .agents directory.
golang-project-layout
Agent skill fromsamber/cc-skills-golang
Golang project layout and workspace setup — cmd/internal/pkg directory conventions, module and package naming, go.work workspaces, and essential configuration files. Use when starting a new Go project, organizing an existing codebase, setting up a monorepo with multiple packages, creating CLI tools with multiple main packages, or discussing package restructuring, package splits, or module splits. Not for restructuring existing code without a layout change (→ See `samber/cc-skills-golang@golang-refactoring` skill).
How to install golang-project-layout
npx skills add samber/cc-skills-golang# or add only this skill to Claude Code: copy the folder
skills/golang-project-layout/
# into
~/.claude/skills/golang-project-layout/ (all projects)
.claude/skills/golang-project-layout/ (one project)
1**Persona:** You are a Go project architect. You right-size structure to the problem — a script stays flat, a service gets layers only when justified by actual complexity.23**Questions:** Ask the user through the environment's question tool — never as plain-text prose. Architecture preference and DI approach are asked one at a time, in that order, waiting for each answer before proceeding — getting either wrong early cascades into every file created afterward.45# Go Project Layout67## Architecture Decision: Ask First89When starting a new project, **ask the developer** what software architecture they prefer (clean architecture, hexagonal, DDD, flat structure, etc.). Avoid over-structuring small projects — a 100-line CLI tool does not need layers of abstractions or dependency injection.1011→ See `samber/cc-skills-golang@golang-design-patterns` skill for detailed architecture guides with file trees and code examples.1213## Dependency Injection: Ask Next1415After settling on the architecture, **ask the developer** which dependency injection approach they want: manual constructor injection, or a DI library (samber/do, google/wire, uber-go/dig+fx), or none at all. The choice affects how services are wired, how lifecycle (health checks, graceful shutdown) is managed, and how the project is structured. See the `samber/cc-skills-golang@golang-dependency-injection` skill for a full comparison and decision table.1617## 12-Factor App18…
Excerpt shown under the repository's MIT license.
More skills in cc-skills-golang
Similar skill repositories
An agentic skills framework & software development methodology that works.
A single CLAUDE.md file to improve Claude Code behavior, derived from Andrej Karpathy's observations on LLM coding pitfalls.
Public repository for Agent Skills
Makes your AI agent think like the laziest senior dev in the room. The best code is the code you never wrote.
Persistent Context Across Sessions for Every Agent – Captures everything your agent does during sessions, compresses it with AI, and injects relevant context back into future sessions. Works with Claude Code, OpenClaw, Codex, Gemini, Hermes, Copilot, OpenCode + More
