golang-patterns

堅牢で効率的かつ保守可能なGoアプリケーションを構築するための慣用的なGoパターン、ベストプラクティス、規約。

Content Preview
---
name: golang-patterns
description: 堅牢で効率的かつ保守可能なGoアプリケーションを構築するための慣用的なGoパターン、ベストプラクティス、規約。
---

# Go開発パターン

堅牢で効率的かつ保守可能なアプリケーションを構築するための慣用的なGoパターンとベストプラクティス。

## いつ有効化するか

- 新しいGoコードを書くとき
- Goコードをレビューするとき
- 既存のGoコードをリファクタリングするとき
- Goパッケージ/モジュールを設計するとき

## 核となる原則

### 1. シンプルさと明確さ

Goは巧妙さよりもシンプルさを好みます。コードは明白で読みやすいものであるべきです。

```go
// Good: Clear and direct
func GetUser(id string) (*User, error) {
    user, err := db.FindUser(id)
    if err != nil {
        return nil, fmt.Errorf("get user %s
How to Use

Recommended: Install to project (local)

mkdir -p .claude/skills
curl -o .claude/skills/golang-patterns.md \
  https://raw.githubusercontent.com/affaan-m/everything-claude-code/main/docs/ja-JP/skills/golang-patterns/SKILL.md

Skill is scoped to this project only. Add .claude/skills/ to your .gitignoreif you don't want to commit it.

Alternative: Clone full repo

git clone https://github.com/affaan-m/everything-claude-code

Then reference at docs/ja-JP/skills/golang-patterns/SKILL.md

Related Skills