← スキル一覧に戻る

go-precommit
by mway
⭐ 4🍴 0📅 2026年1月22日
SKILL.md
name: go-precommit description: Run full pre-commit workflow for Go code. Use when preparing to commit Go changes, before creating pull requests, or ensuring code quality. allowed-tools: ["shell"] metadata: short-description: Run Go pre-commit checks
Go Pre-Commit Workflow
Read these references:
~/.config/agent/domain/coding/go/tooling.md- Go command details~/.config/agent/domain/coding/quality.md- Quality requirements (all steps blocking)
Instructions
Execute the full pre-commit workflow in order. All steps are blocking - stop on first failure.
Step 1: Format and Lint (with auto-fix)
golangci-lint run --new-false --fix ./...
Wait for completion. If errors occur, investigate and fix before proceeding.
Step 2: Run Tests (with race detection and coverage)
go test -race -count 1 -coverprofile=cover.out ./...
All tests must pass. If failures occur:
- Read test output carefully
- Identify root cause
- Fix issues
- Re-run from Step 1
Step 3: Final Lint Check (verify no unfixed issues)
golangci-lint run --new-false ./...
Ensures all lint issues are resolved. Any errors indicate problems introduced during fixes.
Failure Handling
Per AGENT.md Problem-Solving Framework:
- Understand: Read error output carefully
- Plan: Identify root cause and fix strategy
- Execute: Apply fix methodically
- Verify: Re-run workflow from beginning
- Reflect: Consider what caused the issue
Success Criteria
All three steps must pass with zero errors before code is ready for commit.
スコア
総合スコア
40/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です