commit
変更をコミット。差分を分析し、リポジトリのスタイルに合わせたコミットメッセージを自動生成する。
Installation
Follow the repository instructions for this skill and your agent. Review the files and dependencies before adding it to your workflow.
View source ↗GuidesSkill instructions
Commit
変更をコミットします。
手順
1. 状態確認
以下を並列実行:
git status
git diff
git diff --cached
git log -10 --oneline --no-decorate
2. ステージング
変更がある場合、関連ファイルをステージング:
git add <files>
除外対象:
- シークレット(.env, credentials.json 等)
- 一時ファイル(*.log, *.tmp 等)
3. 変更内容の理解
-
git diff --cached --name-onlyで変更ファイルを確認 - 主要ファイルを Read で読み取り
- 変更の目的・影響範囲を把握
4. コミット実行
メッセージ要件:
- 変更の「why」に焦点(1〜2文)
- 適切なプレフィックス: feat, fix, refactor, docs, chore 等
- リポジトリの既存スタイルに準拠
git commit -m "$(cat <<'EOF'
<prefix>: <簡潔な説明>
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet <noreply@anthropic.com>
EOF
)"
5. 確認
git status
git log -1 --stat
完了報告
- コミットメッセージ
- 変更ファイル数
- 推奨する次のアクション(push / PR作成)
Examples
Read the usage examples in the source repository.
View source ↗Source history
- Indexed on
- 2026-01-20
- Index updated
- 2026-01-26
- Branch
- main
Index and sync dates describe this directory. View the source repository for code history.
GitHub ↗chat Comments (0)
Sign in to join the discussion and leave a comment.
No comments yet. Be the first to share your thoughts!