git-commit

A tool that examines staged Git changes and creates a Chinese commit message using Conventional Commits, a shared format such as feat, fix, or docs followed by a short description.

In plain words
What is it for?
Use it when you need to stage changes, generate a commit message from the diff, and commit the work directly.
Why use it?
It turns the current changes into a consistent commit message and stages files first when needed, so commits are easier to understand and search.

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/astordu/qoderharness/git-commit
Any agent
npx skills add astordu/qoderharness --skill git-commit
Clone the repo
git clone --depth 1 https://github.com/astordu/qoderharness

Made for: Claude Code, Codex.

Per session 45 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 762 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.00045 $0.00762
Opus 5 $0.00023 $0.00381
Sonnet 5 $0.00009 $0.00152
Haiku 4.5 $0.00005 $0.00076

Measured yesterday against content hash 74dd520777ea, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

git-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 yesterday.

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.

.qoder/skills/git-commit/SKILL.md · 100 lines

What it actually says

Git Commit

分析暂存区变更,生成 Conventional Commits 格式的中文提交信息并提交。

工作流程

1. 检查变更

git status
git diff --stat
git diff --cached --stat
git diff
git diff --cached
  • 若有未暂存的变更,自动执行 git add 将所有变更文件加入暂存区
  • 若暂存区和工作区均无变更,提示用户无可提交内容

2. 生成 commit message

根据变更内容推断 type 和 scope,用中文编写描述:

type 枚举(必须使用以下之一):

type 含义
feat 新功能
fix 缺陷修复
docs 文档变更
style 格式调整(不影响逻辑)
refactor 重构(非新功能、非修复)
perf 性能优化
test 测试相关
chore 构建/工具变更

scope:从变更涉及的模块推断,如 authapiuidb。跨模块时省略 scope。

格式

<type>(<scope>): <中文简述>

<body: 可选,补充说明>

示例

feat(heart-rate): 添加心率手动录入功能

- 新增录入 Modal 组件
- 添加 POST /heart-rate 接口
- 编写 service 层 TDD 测试
fix(api): 修复仪表盘数据聚合查询超时

添加索引并优化 SQL 查询逻辑
refactor: 将 schemas 目录重命名为 dtos

3. 直接提交

  1. 将生成的 commit message 展示给用户
  2. 直接执行提交,无需等待用户确认
  3. 必须分两步执行:先单独执行 git add,再单独执行 git commit(不要用 && 合并为一条命令),确保 PreToolUse hook 能正确检测暂存区内容
  4. 执行提交命令:
# 第一步:暂存文件(单独执行)
git add <files>

# 第二步:提交(单独执行)
git commit -m "<commit message>"
  • 若 message 含多行,使用 heredoc:
git commit -m "<首行>" -m "<body 内容>"

⚠️ 重要git addgit commit 必须作为两次独立的 run_in_terminal 调用,因为 PreToolUse hook 在命令执行前触发,合并执行时暂存区仍为空,hook 无法检测到已暂存的文件。

4. 禁止事项

  • 自动执行 git add 将变更加入暂存区,无需用户手动操作
  • 不要 使用 --no-verify
  • 不要 使用 --force
  • 不要 执行 git push,除非用户明确要求
  • 不要 修改 git config
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. yesterday First seen · 100 lines · 45 tokens per session scan A 74dd520777ea

Subscribe to this mod's changes

git-commit is a skill published in the GitHub repository astordu/qoderharness (21 stars, last pushed 6d ago), licensed MIT. It adds 45 tokens to every session and 762 once invoked, about $0.0002 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

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

babysit-pr

Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…

openai/codex · 114 tokens

imagegen

Generate or edit raster images when the task benefits from AI-created bitmap visuals such as photos, illustrations, textures, sprites, mockups, or transparent-background cutouts. Use when Codex should create a brand-new image, transform an existing image, or derive visual variants from references, and the output…

openai/codex · 113 tokens

cpu-profile-analysis

Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…

microsoft/vscode · 71 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens