write-commit-message

Generate conventional commit messages from Git diffs.

3|1|Updated Jun 20, 2016
One-click install
npx skills add https://github.com/paulchiu/dotfiles --skill write-commit-message-paulchiu
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: write-commit-message
Source: https://github.com/paulchiu/dotfiles/tree/main/.config/opencode/skills/write-commit-message
Command: npx skills add https://github.com/paulchiu/dotfiles --skill write-commit-message-paulchiu

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Conventional commits are often hard to craft; this skill generates standardized commit messages directly from the current branch changes to save time and improve history quality.

Core Features & Use Cases

  • Automatic commit message generation: Derives type, scope, and subject from diffs of staged or unstaged changes.
  • Branch-code integration: If the branch name contains an issue code, prefixes the message or associates it per rules.
  • Multi-file support: Handles changes across multiple files, producing a clean body when needed.
  • Use Case: When you are ready to commit, generate a conventional commit message and apply it to your changes.

Quick Start

Ask the system to generate a conventional commit message from the current changes.

Frequently Asked Questions about write-commit-message

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automatically generate conventional commit messages from git diffs?

You can automatically generate conventional commit messages from git diffs by analyzing staged or unstaged changes to derive the commit type, scope, and subject. This standardizes Git history and supports both single-file and multi-file scenarios.

How does branch name issue code integration work for commit messages?

Branch name issue code integration works by extracting the issue code from the current branch name and prefixing or associating it within the generated conventional commit message according to predefined rules.

Can I generate commit messages for multiple file changes in a git repository?

Yes, you can generate commit messages for multiple file changes in a git repository. The system handles changes across multiple files and produces a clean commit body when needed to summarize the multi-file diff.

What conventional commit types are supported when generating messages from diffs?

Supported conventional commit types include feat, fix, refactor, test, chore, docs, style, perf, build, and ci. The appropriate type is automatically determined by analyzing the content of the git diff.

Does this work with unstaged changes on the main branch?

Yes, this works with both staged and unstaged changes in a Git repository on the main branch. It automatically analyzes the current branch changes to produce the standardized commit message.