commit

A workflow for recording workspace changes in Git, the version-control system used to track code history. It includes locking, coordination checks, commit conventions, and cleanup if the process stops.

In plain words
What is it for?
Use it whenever the user asks to commit, submit, or organize current changes into Git history.
Why use it?
It prevents simultaneous commit workflows from interfering with each other or accidentally including another session's staged changes.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/yudefine/nuxt-supabase-starter/commit
Any agent
npx skills add YuDefine/nuxt-supabase-starter --skill commit
Clone the repo
git clone --depth 1 https://github.com/YuDefine/nuxt-supabase-starter

Made for: Claude Code, Codex.

Per session 84 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 10,426 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00084 $0.10426
Opus 5 $0.00042 $0.05213
Sonnet 5 $0.00017 $0.02085
Haiku 4.5 $0.00008 $0.01043

Measured 2d ago against content hash f20315337b8e, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

commit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

template/.claude/skills/commit/SKILL.md · 471 lines

How it starts

The opening of the file, as written. The whole thing — 471 lines — stays where its author put it; the contents beside it link to each section on GitHub.

User Input

$ARGUMENTS

政策與禁止事項見 .claude/rules/commit.md。本檔定義執行流程,commit 類型 / emoji 對照表在 Step 3。

Step 0-Lock: 單一 session 防呆(必做第一步

node .claude/scripts/commit-lock.mjs acquire

失敗(exit 1)時照它印出的「處置」段做——那段是依鎖上的持有者身分算出來的、由上往下第一個成立的動作,且每一列都是本 session 自己做得到的:herdr pane 對話 → SendMessage → 等 stale 自動清 → 才輪到回報 user。

NEVER 一撞鎖就問 user。 使用者要的是「鎖上看得到持有者是誰、怎麼聯絡」然後自行協商;把鎖資訊原樣貼給 user 請他裁決,只在腳本自己判定「無從對話」(鎖上沒有 session id)那一格才成立。NEVER 自行 rm 鎖檔繞過。

腳本已自動處理的兩格,撞到時不必做任何事:本 session 的遺留鎖(session id 相符,/commit 被中斷留下的)會自動回收;stale 鎖(超過閾值)也會自動清。所以「PID 看起來死了」NEVER 是清鎖的理由——每個 Bash tool call 都換 pid,pid 從來就判不出存活,判據是 session id。

成功後此 session 取得獨占權,直到最後一步釋放。中斷處理:若 /commit 流程中途失敗 / 使用者中斷,仍必須在終止前呼叫 node .claude/scripts/commit-lock.mjs release;漏釋放的鎖會在 30 分鐘後被下次 acquire 自動清除(可用 COMMIT_LOCK_STALE_MINUTES 調整)。

Step 0-Coord: Cross-Session Staged Pollution Detection

跑 3 個 detection signal(index.lock mtime、publish stash sidecar、wt-helper baseline stash)warn-only 偵測別 session 的 staging 活動。全部 silent → 直接進 Step 0-Scope。任一命中 → 先判持有者性質,持有者是前景 agent sessionMUST 先 herdr agent prompt 跟它對話,對方沒回應才輪到 AskUserQuestion 二擇一。

觸發 0-Coord 命中時 MUST 先完整讀 gates.md § 0-Coord 的 signal 定義與命中處置流程再繼續——NEVER 憑本段摘要直接開 AskUserQuestion,對話那一步只寫在 gates.md 的分流表裡。

Step 0-Pi: 派 pi 跑 commit 工作時的路由規約

主線從 commit SKILL 派 pi 跑 commit 工作時(例如 /wt worktree 內派 pi commit phase),MUSTrules/core/agent-routing.pi-watch-protocol.md § Pi 派工的標準流程 + Pi Watch Protocol。禁止 Agent tool with subagent_type: screenshot-review 派視覺 QA — sonnet wrapper 派工已多次驗證 self-rationalize(per [[pitfall-screenshot-review-sonnet-wrapper-self-rationalize]])。

Step 0-Scope: WIP 預設全部納入(果斷,不徵詢)

預設行為:所有 git status 顯示的 uncommitted 變更(含與本次工作無關、其他 session 並行的 WIP、不認得的檔案)一律無條件列入本次 /commit 流程,照常跑 0-A review、在 Step 3 依功能分組成獨立 commit。

Read the full file on GitHub · 471 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 471 lines · 84 tokens per session scan A f20315337b8e

Subscribe to this mod's changes

commit is a skill published in the GitHub repository YuDefine/nuxt-supabase-starter (45 stars, last pushed 4d ago), licensed MIT. It adds 84 tokens to every session and 10,426 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

contributing

How to contribute to evlog, covering commit and PR conventions, changesets, the Definition of Done, testing rules, and the authored skills that walk through building a new adapter, enricher, framework integration, or map rule. Load this for any question about contributing, opening a PR, or adding something to the…

HugoRCD/evlog · 68 tokens

check-and-commit

Pre-commit verification gate — runs Carbon's validation gates in order (generate:types if schema changed, biome, scoped typecheck, scoped tests, build if needed, and /translate to fill missing i18n .po strings when UI/locale files changed), fixes straightforward failures, then commits the specific files with a…

crbnos/carbon · 117 tokens

atomic-commit

Atomic git workflow - validates, commits, pushes, creates PR/MR, and verifies CI with zero-warnings policy. Orchestrates complete code submission as state machine with rollback on failure. Supports GitHub (gh) and GitLab (glab). Triggers: "commit changes", "push and create PR", "submit code", "atomic commit".

d-oit/rust-2026-template · 76 tokens

remote-fix

Remote fix workflow. Receives a diagnostic (from Cowork scheduled task, manual observation, or user report), investigates the issue, fixes it, and creates a PR. Designed for quick fixes triggered remotely via Channels (Discord/Telegram). Use when the user says "fix this", "handle this diagnostic", "the scheduled task…

rbah31/claude-code-workflow · 80 tokens

git-workflow-and-versioning

Structures git workflow practices. Use when making any code change. Use when committing, branching, resolving conflicts, opening or reviewing a pull request (PR), pushing to a remote, or when you need to organize work across multiple parallel streams. Use when cutting a release, choosing a semantic version bump…

addyosmani/agent-skills · 74 tokens

prowler-commit

Creates professional git commits following conventional-commits format. Trigger: When creating commits, after completing code changes, when user asks to commit.

prowler-cloud/prowler · 33 tokens