← スキル一覧に戻る
name: git-commit-instructions
description: "Practical Git hygiene for staging and committing: review diffs, stage intentionally, avoid committing noise/build artifacts/secrets, and recover from accidental staging or committing. Use when a user asks how to commit changes, write a commit workflow checklist, unstage/remove accidental files, or verify

git-commit-instructions
by wesen
⭐ 0🍴 0📅 2026年1月23日
SKILL.md
name: git-commit-instructions
description: "Practical Git hygiene for staging and committing: review diffs, stage intentionally, avoid committing noise/build artifacts/secrets, and recover from accidental staging or committing. Use when a user asks how to commit changes, write a commit workflow checklist, unstage/remove accidental files, or verify .gitignore behavior."
Git Commit Instructions
Overview
Use this checklist to keep commits focused, reviewable, and free of build artifacts and other noise.
Before Every Commit
git status --porcelain
git diff --stat # unstaged changes
git diff --cached --stat # staged changes
Stage Intentionally (preferred)
git add path/to/file.go path/to/dir/
Use git add -A only when you are sure you want every change.
Inspect What Will Be Committed
git diff --cached --name-only
Commit Pattern
git commit -m "Short summary of change"
git rev-parse HEAD
Never Commit (common noise)
Avoid committing:
node_modules/,vendor/dist/,build/,out/.env,.env.local- binaries (
*.exe,*.bin, etc.) - logs (
*.log) - OS/IDE junk (
.DS_Store,Thumbs.db,.idea/,.vscode/unless shared) - test artifacts (
coverage/,*.cover) - temp dirs (
tmp/,temp/)
Quick Checks
git status --ignored
git check-ignore -v path/to/file
If You Accidentally Staged Something
git reset HEAD path/to/file # unstage one file
git reset HEAD # unstage everything
If Noise Got Committed
git rm --cached path/to/noise
echo "path/to/noise" >> .gitignore
git add .gitignore
git commit --amend --no-edit # if it was the last commit
Reference
Load references/git-commit-instructions.md for the full command list and recovery patterns.
スコア
総合スコア
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
レビュー
💬
レビュー機能は近日公開予定です