CO
commit-push
Commit and push changes (途中保存)
Install
mkdir -p .claude/skills/commit-push && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/14477" && unzip -o skill.zip -d .claude/skills/commit-push && rm skill.zipInstalls to .claude/skills/commit-push
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Commit and push changes (途中保存)30 charsno explicit “when” trigger
About this skill
Commit & Push(途中保存)
変更をコミット&プッシュ(途中保存、Issueは開いたまま)
重要:
- このコマンドは途中保存用です
- Issueはクローズしません
- Worktreeは削除しません
- タスク完了時は
/issue/finishまたは/commit/mergeを使用
vs /commit/merge
| 特徴 | /commit/push | /commit/merge |
|---|---|---|
| 目的 | 途中保存 | タスク完了 |
| レビュー | 簡易 | 品質チェック |
| PR作成 | ❌ なし | ✅ 作成 |
| マージ | ❌ なし | ✅ squash merge |
| Issueクローズ | ❌ しない | ✅ する |
| Worktree削除 | ❌ しない | ✅ する |
Workflow
Phase 0: 簡易レビュー
Step 0: QA回答の確認
コミット前に未確認のQA回答がないか確認:
# docs/qa/answers.jsonl をチェック
if [ -f "docs/qa/questions.jsonl" ]; then
echo "QA回答を確認中..."
fi
新しい回答がある場合:
- 回答内容を表示
- 仮決定と異なる場合は、変更が必要か確認
- 必要に応じて実装を修正してからコミット
Step 1: 変更内容を確認
git status
git diff --stat
-
簡易品質チェック 以下の観点で変更をチェック:
- ✓ 明らかな問題: 未完成のコード、デバッグ用コード、コメントアウトされたコード
- ✓ セキュリティ: 機密情報の混入(API key、password等)
- ✓ データ保護: 重要データが
data/local/ではなくdata/shared/に保存される設計か - ✓ ハードコーディング: 明らかなマジックナンバーや固定パスがないか
- ✓ テスト: テストの追加が必要な変更がないか
-
問題があれば指摘
- 重大な問題: コミット前に修正を提案
- 軽微な問題: 注意点として報告しつつコミット続行
Phase 1: Commit & Push
-
すべての変更をステージング
git add . -
コミット
- Conventional Commits 形式を使用
- Issue番号を含める(
Refs #ISSUE_ID) - Claude Code署名を含める
-
プッシュ
git push -u origin $(git branch --show-current)
Phase 2: 進捗報告
- Issueに進捗報告
- コミットハッシュ
- 変更ファイル数
- 次のステップ
Implementation
現在のブランチから Issue 番号を取得:
BRANCH=$(git branch --show-current)
ISSUE_ID=$(echo "$BRANCH" | grep -oE '[0-9]+' | head -1)
# エラーチェック
if [ -z "$ISSUE_ID" ]; then
echo "Error: Could not extract Issue ID from branch name: $BRANCH"
echo "Branch name must contain Issue number (e.g., feature/123-description)"
exit 1
fi
変更をステージング&コミット:
git add .
git commit -m "適切なコミットメッセージ
Refs #${ISSUE_ID}
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>"
プッシュ:
git push -u origin $(git branch --show-current)
Issueに報告:
gh issue comment "$ISSUE_ID" --body "## コミット完了(途中保存)
- コミット: [hash]
- 変更: [files]
- 次のステップ: [...]
---
*Issueは開いたままです。タスク完了時は `/issue/finish` を実行してください。*"
Output
- 簡易レビュー結果(問題があれば)
- コミットハッシュ
- 変更ファイル数
- Issue コメント URL
- 次のステップの案内
Note
このコマンドは途中保存用です。
タスクが完了したら /issue/finish を実行してください。