git-commit-guide

A guide for making Git commits, which are saved snapshots of code changes, in small logical units with consistent messages and pre-commit checks.

In plain words
What is it for?
Use it when deciding when to commit, choosing a commit type such as feature or fix, and checking linting, tests, and the change scope first.
Why use it?
It makes changes easier to review, understand, revert, and connect to release versioning.

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

Made for: Claude Code, Codex.

Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 831 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.00048 $0.00831
Opus 5 $0.00024 $0.00415
Sonnet 5 $0.00010 $0.00166
Haiku 4.5 $0.00005 $0.00083

Measured yesterday against content hash 1dfdc6959541, 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-guide 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.

git/git-commit-guide/SKILL.md · 75 lines

What it actually says

git-commit-guide

定义提交的时机格式。项目专属的前缀约定(如 feat(backend): / feat(xxx):)由各项目 AGENTS.md 声明。

Leading Words

术语 定义
一个 commit 只做一件事 单次提交只包含一个逻辑变更,方便 review 和回退
小步快跑 完成一个小功能点立即提交,不攒着
自检门 提交前必须通过检查清单——lint、测试、变更范围

提交时机

时机 示例
完成一个小功能点 "新增 ETF 数据获取器"
修复一个 bug "修复 K 线日期格式解析错误"
重构一个模块 "提取公共清洗逻辑为独立模块"

信息格式(通用部分)

<type>: <简短描述>

- 变更点 1
- 变更点 2
类型 含义
feat 新功能
fix Bug 修复
refactor 重构(不改变功能)
docs 文档
chore 构建/依赖/工具
test 测试
style 格式(不影响逻辑)

项目专属前缀

前缀格式由各项目 AGENTS.md 声明。 例如:

  • TDX 项目:feat(xxx): 单项目格式
  • trading_assistant:feat(backend): / feat(frontend): 前后端区分

选择提交前缀时,优先匹配当前项目的 AGENTS.md 声明;无声明则使用通用类型(feat/fix/refactor 等)。

提交类型 → 版本号递增(SemVer 联动)

提交类型决定下一次发布时的版本号递增(见 changelog-guide 校验):

提交类型 SemVer 递增
feat 次版本号 Y(新增向下兼容功能)
fix 修订号 Z(修复问题,不影响 API)
feat!: / 含 BREAKING CHANGE 主版本号 X(不兼容修改)
refactor / docs / chore / style / test 无版本递增(除非累计显著变更)

! 前缀表示破坏性变更——如 feat!: 重命名 getPrice 为 fetchPrice。含不兼容修改的提交必须在 message 中标注,否则版本号无法正确递增。

提交前自检

git commit 之前:

  • 变更是否只属于一个逻辑主题?
  • 提交信息是否描述了"做了什么"和"为什么"?
  • 项目 lint 是否通过?
  • 是否遵守了 git-guardrails 的安全约束?
  • 是否含不兼容修改?若是,已用 !BREAKING CHANGE 标注?
  • 功能级变更是否需要同步更新 CHANGELOG(格式校验见 changelog-guide)?
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 · 75 lines · 48 tokens per session scan A 1dfdc6959541

Subscribe to this mod's changes

git-commit-guide is a skill published in the GitHub repository Grid0723/skills (2 stars, last pushed 10d ago), licensed MIT. It adds 48 tokens to every session and 831 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-31.

Related

Other skills, from other repositories

happiness-skill

当用户问「怎么才能更幸福/为什么得到了还不满足/怎么减少焦虑」时调用。 核心理念: 幸福是缺憾感清空的默认状态, 是可训练的技能; 欲望是与自己的契约(得到前不快乐), 同时只留一个重大欲望; 活在当下。 不适用于: 临床抑郁等需要专业治疗的场景(本书方法不能替代医疗)。 Triggers: 幸福/不快乐/欲望/焦虑/知足/活在当下/happiness/desire/anxiety.

kangarooking/cangjie-skill · 136 tokens

create-modal

Create declarative modals using the modal library API. Covers modal types (confirm, input, select, form), sections (Text, Buttons, Input, Textarea, Checkbox, List, Combo, When, Custom), rendering with OverlayModal, and keyboard/mouse handling. Use when adding modals or dialogs to the application.

marcus/sidecar · 69 tokens

merge-strategy

Git merge strategies, conflict resolution approaches, merge vs rebase recommendations, and branch integration patterns in sidecar. Covers pull strategy menu, direct merge workflow, squash merge, commit message templates, configurable defaults, and protected branches. Use when working on git merge features or making…

marcus/sidecar · 63 tokens

autoprompt

Explicit-only useful-first orchestration. Invoke /autoprompt to turn a mission into one executable roadmap, build dependency-safe lanes, and verify the result with independent reviewers. Never infer invocation from ordinary requests. Never resume from leftover artifacts without an explicit resume instruction.

Spielewoy/autoprompt-skill · 56 tokens

autoprompt

Explicit-only useful-first orchestration. Invoke /autoprompt to turn a mission into one executable roadmap, build dependency-safe lanes, and verify the result with independent reviewers. Never infer invocation from ordinary requests. Never resume from leftover artifacts without an explicit resume instruction.

Spielewoy/autoprompt-skill · 56 tokens

bug-triage

Read all open bugs in production/qa/bugs/, re-evaluate priority vs. severity, assign to sprints, surface systemic trends, and produce a triage report. Run at sprint start or when the bug count grows enough to need re-prioritization.

Donchitos/Claude-Code-Game-Studios · 59 tokens