mine-commit-push
Use when the user says: "commit and push". Commits and pushes changes to the current branch.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Use when the user says: "commit and push". Commits and pushes changes to the current branch.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
'Use this when the users says: "review existing feature","make this change"
Use when the user says: "extract learnings", "save this for next time", "remember this pattern", "consolidate memories", "dream", "clean up memories".
Use when the user asks about Claude token usage, wants to see how much they are spending on Claude, understand cache hit rates, review Claude Code workflow patterns, or get cost optimization recommendations.
Use when the user asks to recall, search, or continue past conversations. Triggers on "what did we discuss", "continue where we left off", "remember when", "as I mentioned", "you suggested", "we decided", "search my conversations", "find the conversation where", "what did we work on". Also triggers on implicit signals like past-tense references ("the bug we fixed"), possessives without context ("my project"), or assumptive questions ("do you remember").
Generate a commit message
Manage conversations and task context
| name | mine.commit-push |
| description | Use when the user says: "commit and push". Commits and pushes changes to the current branch. |
| user-invocable | true |
git statusgit diff HEADgit branch --show-currentThis skill handles the shared "commit & push with quality gates" phase. It can be used standalone (when the user asks to commit and push) and is also used as Phase 1 of mine.ship. Compared to mine.ship, it omits the PR creation phase but includes the same code quality gates (code review, integration review, tests, linting) and pre-commit checks (test presence, WP archival).
Based on the above changes:
If on the default branch (run git-default-branch to check), create a new branch first.
COMMIT SCOPE CHECK: Review the diff for unrelated changes that belong in separate commits (e.g., a feature + an unrelated bug fix, or a config change mixed with new functionality). If the changes clearly span distinct concerns, ask the user whether to split them into separate commits before proceeding. If the changes are all part of one logical unit of work, continue.
CHANGELOG CHECK (mandatory — never skip this step): Locate the nearest CHANGELOG.md using this algorithm: walk upward from the current working directory one level at a time toward the repo root, checking each directory for CHANGELOG.md — the first one found is the nearest, use it. If no CHANGELOG.md is found by walking up, run git ls-files '*CHANGELOG.md' to find any changelogs elsewhere in the repo and pick the one with the shortest relative path from CWD. If none exist anywhere, skip this step. Use the Read tool on the specific path identified — do NOT treat a failed read of ./CHANGELOG.md as proof that no changelog exists. Once read, decide whether the changes deserve a changelog entry:
## [Unreleased] sections or date-based sections (## YYYY-MM-DD). Add entries under the appropriate heading — either the existing [Unreleased] section or today's date section (creating it if needed). Keep them high-level and terse — one bullet per change, two at most. These are user-facing entries; describe what changed for the user, not implementation details.CODE REVIEW LOOP (skip for documentation-only changes): Run the code-reviewer agent on the current changes. For each finding:
After applying fixes, re-run code-reviewer and repeat until no CRITICAL or HIGH issues remain or only LOW/noise is left. If the same CRITICAL or HIGH findings appear again and cannot be auto-fixed, defer to the user — do not proceed to commit.
INTEGRATION REVIEW (skip for documentation-only changes): Run integration-reviewer once on the final state of the changes (after the code-reviewer loop). Address any CRITICAL or HIGH findings; defer ambiguous ones to the user.
LOCAL VERIFICATION (skip for documentation-only changes):
rules/common/testing.mdtesting.md):
Review the branch diff (git diff --name-only against the default branch). If the diff contains new or changed source files but zero changes in test files (no files matching common test patterns like test_*, *_test.*, *_spec.*, __tests__/), mention this to the user and ask whether to proceed or stop to write tests.
This is advisory, not a hard block — the user decides.ruff check for Python, eslint for JS). Fix any issues.Stage all relevant files (including CHANGELOG.md if updated).
For multi-line commit messages, run get-skill-tmpdir mine-commit to create a temp directory, then write the message to <dir>/message.md and run git commit -F <dir>/message.md. For simple one-line messages, git commit -m "..." is fine. Do NOT use git commit -m "$(cat <<'EOF'...)" — command substitution triggers extra permission prompts.
Push the branch to origin (use -u flag only if you just created a new branch).
You MUST do steps 7–9 in a single message. Include the Write call for the commit message file (if needed) in that same message. Do not use any other tools or do anything else besides these tool calls.
WP ARCHIVAL REMINDER: If design/specs/ exists in the repo and spec-helper is available (command -v spec-helper), run spec-helper archive --dry-run --json. If any entries have status: "would_archive", tell the user: "These specs are ready to archive: [list]. Run spec-helper archive --all to clean up tasks/ directories before merging." If none qualify, design/specs/ doesn't exist, or spec-helper isn't installed, skip silently.