skills/commits/SKILL.md
Commit necessary changes with appropriate separation. Use when: (1) User says 'commit', 'commits', or 'save changes', (2) Claude has made changes that need committing, (3) User wants commits with proper grouping and conventional messages. Handles .gitignore updates, file selection, logical grouping, clean commit messages.
npx skillsauth add takazudo/claude-resources commitsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Make commits for all necessary changes in the working directory.
Check $ARGUMENTS for these flags (case-insensitive, hyphens optional):
/push-forbid to disable automatic pushing for the rest of the session./push-auto to enable automatic pushing for the rest of the session.Offload the commit workflow to a Haiku subagent so the expensive main session context (the session model — currently Fable 5) only sees a summary — not the full git diff, file-selection reasoning, or commit-message drafting.
Before anything else, run these two checks via Bash:
git status --porcelain
git rev-list --count @{upstream}..HEAD 2>/dev/null || echo "unknown"
Based on the results:
push argument present → No subagent needed. Run git pull --rebase && git push directly. Report and stop. Done.push argument present → New branch with no remote tracking. Run git push -u origin $(git branch --show-current). Report and stop. Done.push argument → Report "Nothing to commit. N commit(s) ahead of remote — use /commits push to push." and stop. Done.Spawn a Haiku subagent using the Agent tool with model: "haiku". Give it the full Instructions section below as its prompt, plus the current repo path and whether push is requested. The subagent runs in its own isolated context — the main session context (the session model — currently Fable 5) only sees the final report, not the intermediate git diff/status output.
If the subagent reports success: stop here. Done.
If the subagent fails (partial commits, rebase conflict, or any error): run git status and git log --oneline to assess current state, then continue with Attempt 2 for the remainder.
Only if Attempt 1 failed, execute the Instructions below directly in the current session. Handles commit and (if push argument present) push.
If git pull --rebase fails due to a conflict:
If running as a child agent in a team:
git rebase --abortIf running standalone (no team):
git rebase --abort to restore the pre-rebase stategit fetch && git log --oneline HEAD..origin/$(git branch --show-current) to see incoming commitsgit pull --rebase again to see the actual conflictsgit rebase --continue, then git pushgit rebase --abort, then resolve carefully with full awareness of what was implemented before retrying pushgit status to see all modified, staged, and untracked filesgit diff --stat to understand the scope of changesCheck for unwanted files and update .gitignore
Before proceeding, scan the output for files that should never be committed:
Files/directories to exclude:
node_modules/ - Package dependencies
Build outputs: dist/, build/, .next/, out/, *.bundle.js
Log files: *.log, npm-debug.log*, yarn-error.log
Temporary files: *.tmp, *.temp, .cache/, *.swp, *~
OS files: .DS_Store, Thumbs.db, Desktop.ini
IDE files: .idea/, .vscode/, *.sublime-* (unless intentional)
Environment files: .env, .env.local, .env*.local
Test coverage: coverage/, .nyc_output/
Package manager: pnpm-lock.yaml, package-lock.json, yarn.lock (context-dependent)
Secrets/credentials: *.pem, *.key, credentials.json, secrets.*
If unwanted files are found:
Check if .gitignore exists in the project root
If it exists, check if the unwanted patterns are already listed
If patterns are missing, add them to .gitignore
If .gitignore doesn't exist and project has package.json or other project markers, create one with common patterns
After updating .gitignore, the ignored files will no longer appear in git status
If any unwanted files are already staged:
Unstage them with git reset HEAD <file>
If they were previously committed, inform the user they may need to remove them from history
Temporary image/screenshot files (NEVER add to .gitignore):
Image files (*.png, *.jpg, *.gif, *.webp, screenshot SVGs) in the repo root or non-content directories are typically temporary — generated by headless browsers or shared during conversation. Do NOT add glob patterns like *.png to .gitignore. Instead:
If the files appear no longer needed (old screenshots, leftover from previous work): delete them with rm
If the files appear still useful (referenced in the current conversation): move them to the log directory: LOGDIR=$(node $HOME/.claude/scripts/get-logdir.js) && mkdir -p "$LOGDIR" && mv <file> "$LOGDIR/"
Never add image glob patterns to .gitignore — it confuses users about what the pattern is for and may accidentally exclude intentional image assets
Write clear, concise commit messages
Use conventional commit style when appropriate (feat:, fix:, docs:, refactor:, etc.)
Add Co-Authored-By: Claude <[email protected]> if Claude contributed significantly
Use HEREDOC format for commit messages:
git commit -m "$(cat <<'EOF'
Commit message here
Co-Authored-By: Claude <[email protected]>
EOF
)"
push argument is present)git rev-list --count @{upstream}..HEAD 2>/dev/null || echo "unknown""unknown" (no upstream / new branch): run git push -u origin $(git branch --show-current), skip to Verifygit pull --rebase then git pushgit pull --rebase fails with a conflict, follow the Conflict Handling section abovegit status after committing to confirm working tree is cleangit log --oneline -n <number of commits> to show what was committedgit add . blindly - be selective about what to stagegit commit --amend without explicit user permission - Always create new commits by default. Amending commits can be confusing and may cause issues if the original commit was already shared. If you need to fix a previous commit, ask the user first.tools
Acceptance gate for a branch produced by an OpenAI Codex CLI run — usually Codex implementing a /big-plan epic that was handed off to it. Codex reports the work 'done' (or the user flags it WIP with corrections); this skill confirms the branch actually fulfils the original spec, fixes what falls short, and routes larger discoveries into GitHub issues. Use when: (1) User says '/finalize-codex-work', 'finalize codex work', 'confirm the codex work', 'check the codex branch', or 'codex said it's done', (2) A branch is the result of a Codex CLI session and needs verification against its spec issue/PR, (3) After assigning a /big-plan epic to Codex CLI. Pass -m/--merge to run /pr-complete -c at the end.
tools
Read a Figma design node directly from a share URL via the Figma REST API — no Dev Mode subscription, no MCP, no desktop app. Renders the node to PNG and dumps its full style/layout JSON so the design can be described, compared, or implemented. Use whenever the user gives a Figma design URL (figma.com/design/... or /file/...) and wants to see, read, inspect, reference, or implement that node — including `/fig-url-refer <url>`. This is the URL-based counterpart to `/figrefer` (which needs a Dev-plan desktop MCP); prefer this one when the input is a URL rather than a live desktop selection.
tools
Sync the user's Claude Code workflow skills into the OpenAI Codex CLI settings repo ($HOME/.codex) as Codex-native ports, fix the Codex .gitignore for new local state, then commit and push. Use when: (1) user says '/dev-codex-sync-settings-from-claude', 'sync codex settings', 'sync claude skills to codex', 'port skills to codex', or 'update codex from claude'; (2) after updating ~/.claude workflow skills (big-plan, x, x-as-pr, x-wt-teams) and Codex should catch up; (3) the $HOME/.codex repo has drifted behind $HOME/.claude. The ports are condensed Codex-native REWRITES, never file copies.
development
Analyze a video file (mov, mp4, webm, etc.) or a YouTube video by extracting still frames with ffmpeg and reading them chronologically with vision — Claude cannot ingest video files directly. Use whenever the user provides a video file path or YouTube URL and wants to know what happens in it: "read this video", "watch this video", "check this recording", "what happens in this .mov/.mp4", analyzing a screen recording of a UI bug, or verifying UI behavior captured in a video, even if they don't name this skill.