Agent skill

Git Commit Message Writer

by mergisi in mergisi/awesome-openclaw-agents

Drafts a commit message from your staged diff, matching the repo's own style and explaining why the change happened, not just what changed.

MITAuto-check passedDevelopment

Install Git Commit Message Writer

skills CLI
$ npx skills add mergisi/awesome-openclaw-agents --skill git-commit-writer -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install mergisi/awesome-openclaw-agents git-commit-writer --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/mergisi/awesome-openclaw-agents.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/claude/git-commit-writer .claude/skills/git-commit-writer && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
git-commit-writer
GitHub stars
4k
Token cost
~664 tokens
SKILL.md length
370 words
Files
1
Skills in repo
16
Repo updated
First seen
Licence
MIT

At a glance

Drafts a commit message from your staged diff, matching the repo's own style and explaining why the change happened, not just what changed.

  • Works in 5 steps: Run git status --short with the Bash… → Run git diff --staged to read the full… → Run git log --oneline -10 to learn the… → …
  • Writing a commit message for changes you've already staged
  • SKILL.md covers When to use, Instructions, Anti-patterns to reject and Example invocations
  • Calls git

What it does

This skill checks what's currently staged, reads the full diff, then looks at recent commit history to learn the repository's own habits — whether it uses conventional prefixes, title case or sentence case, a body or none, and any ticket-number pattern. It stops and says so if nothing is staged yet.

The drafted title stays in imperative mood under 70 characters with no trailing period, and an optional body explains why the change was needed and what trade-offs were made, in short paragraphs or bullets after a blank line. It rejects vague titles like a bare "various fixes" or "refactor" without naming what was refactored, and it never invents a ticket number it can't infer from history. The message shows up in a code block for review; it won't run the commit itself unless asked to.

When your agent uses it

  • Writing a commit message for changes you've already staged
  • Reviewing a staged diff before committing it
  • Checking what a commit should be called before you write it yourself

Example prompts

  • “Write a commit message for what I have staged.”
  • “Review my staged diff and draft a commit, don't push it.”
  • “What should this commit be called based on the diff?”

Requirements

  • A Git repository with staged changes

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. Run git status --short with the Bash tool. Confirm there are staged changes. If nothing is staged, stop and tell the user.
  2. Run git diff --staged to read the full staged diff. If the diff is large (>500 lines), also run git diff --staged --stat to get a…
  3. Run git log --oneline -10 to learn the repo's commit convention. Look for
  4. Draft a message following these rules
  5. Show the drafted message in a fenced code block. Ask the user if they want you to run git commit with it. Do not commit automatically.

What it can do on your machine

Read from SKILL.md and the folder at commit 05820c5. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • git

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Git Commit Message Writer loads about 664 tokens when it runs. Until then it costs about 63 tokens; SKILL.md has 370 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~63
When it runs · the whole SKILL.md, loaded when a task matches
~664

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from mergisi/awesome-openclaw-agents at commit 05820c5, republished under its MIT licence (© mergisi). 370 words, ~664 tokens.

Download SKILL.mdSave it as .claude/skills/git-commit-writer/SKILL.md (or your agent's skills folder).
name
git-commit-writer
description
Trigger when the user asks to write a commit message, generate a commit from staged changes, review a diff before committing, or says "/commit". Reads git diff --staged and produces an opinionated, convention-matching commit message.

Git Commit Writer

Generate a disciplined commit message from the currently staged changes. Opinionated about style: imperative mood, concise title, body that explains why not what.

When to use

  • User says "write a commit message", "/commit", "commit this"
  • User has staged changes and asks to review them before committing
  • User asks "what should this commit be called"

Do NOT use this skill to actually run git commit unless the user explicitly asks — just draft the message and show it.

Instructions

  1. Run git status --short with the Bash tool. Confirm there are staged changes. If nothing is staged, stop and tell the user.
  2. Run git diff --staged to read the full staged diff. If the diff is large (>500 lines), also run git diff --staged --stat to get a file-level overview first.
  3. Run git log --oneline -10 to learn the repo's commit convention. Look for:
    • Conventional Commits prefixes (feat:, fix:, chore:) — if present, match the style.
    • Title case vs sentence case.
    • Whether bodies are used or not.
    • Any ticket / issue prefix (e.g. [PROJ-123]).
  4. Draft a message following these rules:
    • Title: imperative mood ("Add X", not "Added X" or "Adds X"), max 70 characters, no trailing period.
    • Body (if needed): blank line after title, then 1-3 short paragraphs or bullets explaining why the change is necessary, what problem it solves, what trade-offs were made.
    • Never use the word "refactor" alone — always say what was refactored and why ("Extract retry loop into helper to share with job runner").
    • Never write "Update file.js" — describe the behavior change, not the file touched.
    • Never invent a ticket number. If the repo uses them but you can't infer one, leave it out.
  5. Show the drafted message in a fenced code block. Ask the user if they want you to run git commit with it. Do not commit automatically.
Show full SKILL.md (64 more words)Show less

Anti-patterns to reject

  • "Various fixes" / "Updates" / "WIP" — reject and ask for specifics from the diff.
  • "Refactor code" — must name the unit being refactored.
  • Title >70 chars — shorten or move detail to body.
  • Past tense or "-ing" forms — rewrite to imperative.

Example invocations

  • /git-commit-writer
  • "Write a commit message for what I have staged"
  • "Review my staged diff and draft a commit"
  • "/commit — but don't push"

© mergisi, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/claude/git-commit-writer of mergisi/awesome-openclaw-agents.

Open the folder on GitHubat commit 05820c5

Compare with similar skills

Git Commit Message Writer next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Git Commit Message Writer compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Git Commit Message Writer this skillmergisi/awesome-openclaw-agents4k—~664Automated safety check: PassMIT
ToolJet Multi-Repo CommitToolJet/ToolJet41k—~1.3kAutomated safety check: PassAGPL-3.0
Git Workflow and Versioningaddyosmani/agent-skills102k2 repos~3.5kAutomated safety check: NotesMIT
React Router Pull Request Creatorremix-run/react-router57k—~2.5kAutomated safety check: PassMIT
Saleor Commit Workflowsaleor/saleor23k—~575Automated safety check: PassBSD-3-Clause
Emoji Commit ConventionsbaptisteArno/typebot.io11k—~424Automated safety check: PassCustom licence

Similar skills

  • Commits changes across ToolJet's root repo and its server/ee and frontend/ee submodules, writing messages from the diffs and updating submodule pointers in order.

    41k GitHub stars~1.3k tokensUpdated today
    DevelopmentAuto-check passed
  • Git Workflow and Versioning

    addyosmani/agent-skills

    Sets git habits for every change: short-lived branches, atomic commits with descriptive messages, clean pull requests, plus versioning, tagging and changelogs for releases.

    102k GitHub starsUsed in 2 repos~3.5k tokens
    DevelopmentAuto-check: notes
  • React Router Pull Request Creator

    remix-run/react-router

    Packages finished React Router work into a draft pull request: branch, commit, push, a written PR body and the right GitHub labels.

    57k GitHub stars~2.5k tokensUpdated today
    DevelopmentAuto-check passed
  • Commits changes in the Saleor codebase and works through pre-commit hook failures from ruff, mypy, the GraphQL schema check and the migrations check.

    23k GitHub stars~575 tokensUpdated today
    DevelopmentAuto-check passed
  • Emoji Commit Conventions

    baptisteArno/typebot.io

    Sets the repository's convention for commit messages and pull request titles: one emoji prefix for the main intent, a concise title and clean follow-up commits.

    11k GitHub stars~424 tokensUpdated yesterday
    DevelopmentAuto-check passed
  • Draft Pull Request Creator

    wordpress-mobile/WordPress-Android

    Commits and pushes current changes, writes a pull request title and body from the branch history and template, and opens a draft PR on GitHub after you approve it.

    3.2k GitHub stars~881 tokensUpdated today
    DevelopmentAuto-check: notes

More from mergisi/awesome-openclaw-agents

All 16 skills in this repo
  • Claude Code Cost Optimizer

    mergisi/awesome-openclaw-agents

    Audits a project's Claude Code setup for common token-cost leaks and returns a prioritized fix list, using only static inspection of files and settings.

    4k GitHub stars~1.1k tokensUpdated 10 days ago
    Auto-check passed
  • Excalidraw Architecture Diagram

    mergisi/awesome-openclaw-agents

    Generates or updates a whiteboard-style architecture diagram of the current codebase as an Excalidraw JSON file, showing services and data flow.

    4k GitHub stars~1.1k tokensUpdated 10 days ago
    Auto-check passed
  • Model Cost Compare

    mergisi/awesome-openclaw-agents

    Trigger when the user asks which model to use, wants to compare model costs, says "what's cheapest for this task", "should I use Opus or Sonnet", "can a smaller model handle this", or…

    4k GitHub stars~1k tokensUpdated 10 days ago
    Auto-check passed
  • Openclaw Debugger

    mergisi/awesome-openclaw-agents

    Trigger when an OpenClaw agent is broken, silent, crashing, stuck, not responding, returning empty output, or the user says "my agent is down", "agent not working", "/openclaw-debugger".

    4k GitHub stars~959 tokensUpdated 10 days ago
    Auto-check passed
  • Code Explainer

    mergisi/awesome-openclaw-agents

    Explains a pasted code snippet in plain English, returning the detected language, a one-sentence summary, how it works and one practical tip.

    4k GitHub stars~283 tokensUpdated 10 days ago
    Auto-check passed
  • Commit Message

    mergisi/awesome-openclaw-agents

    Generate a clean, conventional commit message from a description of your changes.

    4k GitHub stars~239 tokensUpdated 10 days ago
    Auto-check passed

Works with

Categories

Questions about Git Commit Message Writer

What does Git Commit Message Writer do?

Drafts a commit message from your staged diff, matching the repo's own style and explaining why the change happened, not just what changed. This skill checks what's currently staged, reads the full diff, then looks at recent commit history to learn the repository's own habits — whether it uses conventional prefixes, title case or sentence case, a body or none, and any ticket-number pattern. It stops and says so if nothing is staged yet.

When should I use Git Commit Message Writer?

Git Commit Message Writer fits situations like: writing a commit message for changes you've already staged; reviewing a staged diff before committing it; checking what a commit should be called before you write it yourself.

How do I install Git Commit Message Writer in Claude Code?

Run `npx skills add mergisi/awesome-openclaw-agents --skill git-commit-writer -a claude-code`. Or copy the skill folder (skills/claude/git-commit-writer in mergisi/awesome-openclaw-agents) into .claude/skills/git-commit-writer in your project. Claude Code loads it when a task matches its description.

How do I install Git Commit Message Writer in Codex?

Run `npx skills add mergisi/awesome-openclaw-agents --skill git-commit-writer -a codex`. Or copy the skill folder (skills/claude/git-commit-writer in mergisi/awesome-openclaw-agents) into .agents/skills/git-commit-writer in your project. Codex loads it when a task matches its description.

Can I use Git Commit Message Writer in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add mergisi/awesome-openclaw-agents --skill git-commit-writer -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/git-commit-writer, .gemini/skills/git-commit-writer, .github/skills/git-commit-writer and .opencode/skills/git-commit-writer in your project.

What does Git Commit Message Writer need to run?

Going by SKILL.md and its folder, Git Commit Message Writer needs the command-line tools its instructions call (git). Our summary lists: A Git repository with staged changes.

Does Git Commit Message Writer access the network?

SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Git Commit Message Writer safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Git Commit Message Writer use?

Git Commit Message Writer is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Git Commit Message Writer use?

About 664 tokens (SKILL.md is roughly 2.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Git Commit Message Writer?

Skills that share tags, products or a category with Git Commit Message Writer: ToolJet Multi-Repo Commit (ToolJet/ToolJet, 41k stars), Git Workflow and Versioning (addyosmani/agent-skills, 102k stars), React Router Pull Request Creator (remix-run/react-router, 57k stars) and Saleor Commit Workflow (saleor/saleor, 23k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Git Commit Message Writer?

mergisi (a GitHub user) maintains it in mergisi/awesome-openclaw-agents, which has 3,995 GitHub stars. The repository holds 16 skills in this directory. The repository was last updated on September 26, 2026.

Source: mergisi/awesome-openclaw-agents on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.