conventional-commit
Create commit messages following the Conventional Commits specification
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Create commit messages following the Conventional Commits specification
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
Run format, lint, test, and build checks on the Rust project. Automatically invoked after completing a task or implementation step. Use this to ensure code quality before moving on.
Use when asking about Rust code style or best practices. Keywords: naming, formatting, comment, clippy, rustfmt, lint, code style, best practice, P.NAM, G.FMT, code review, naming convention, variable naming, function naming, type naming, 命名规范, 代码风格, 格式化, 最佳实践, 代码审查, 怎么命名
CRITICAL: Use for unsafe Rust code review and FFI. Triggers on: unsafe, raw pointer, FFI, extern, transmute, *mut, *const, union, #[repr(C)], libc, std::ffi, MaybeUninit, NonNull, SAFETY comment, soundness, undefined behavior, UB, safe wrapper, memory layout, bindgen, cbindgen, CString, CStr, 安全抽象, 裸指针, 外部函数接口, 内存布局, 不安全代码, FFI 绑定, 未定义行为
| name | conventional-commit |
| description | Create commit messages following the Conventional Commits specification |
| allowed-tools | Bash, Read, Edit, AskUserQuestion |
This skill helps create commit messages following the Conventional Commits specification.
You are a commit message assistant. Your task is to analyze the current changes, split them into logical commits if needed, and create well-formatted commit messages.
Analyze Changes: Run git status and git diff --staged (or git diff if nothing is staged) to understand what has been changed.
Evaluate whether to split: Group changes by their logical purpose. If changes span multiple types (e.g., tests + docs + chore), split into separate commits. Apply these rules:
Determine the Commit Type for each commit:
feat: A new featurefix: A bug fixdocs: Documentation only changesstyle: Changes that do not affect the meaning of the code (white-space, formatting, etc.)refactor: A code change that neither fixes a bug nor adds a featureperf: A code change that improves performancetest: Adding missing tests or correcting existing testsbuild: Changes that affect the build system or external dependenciesci: Changes to CI configuration files and scriptschore: Other changes that don't modify src or test filesrevert: Reverts a previous commitIdentify the Scope (optional): Determine if there's a specific component, module, or area affected.
Write the Description: Create a concise description in imperative mood (e.g., "add feature" not "added feature").
Add Body (if needed): For complex changes, add a body explaining the motivation and contrast with previous behavior.
Add Footer (if needed): Include any breaking changes or issue references.
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
Given these unstaged changes:
src/api/types.rs — added deserialization teststests/fixtures/*.json — new test fixture filesdocs/api-type-guide.md — new documentationCLAUDE.md — added rules about API types.claude/skills/verify/SKILL.md — added test stepSplit into:
test(api): add deserialization tests for API types — types.rs + fixtures/docs(api): add API type definition guide — docs/api-type-guide.md + CLAUDE.mdchore(verify): add cargo test step to verify skill — verify/SKILL.mdAfter analyzing the changes, present the user with:
If the user provides additional context or wants changes, adjust accordingly.
For each commit:
git add <specific files>git commit -m "$(cat <<'EOF'
<commit message here>
EOF
)"
$ARGUMENTS