jj-commit

Generate conventional commit messages by analyzing diffs and running tests.

5|Updated Feb 3, 2024
One-click install
npx skills add https://github.com/ahkohd/dotfiles --skill jj-commit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: jj-commit
Source: https://github.com/ahkohd/dotfiles/tree/main/claude/.claude/skills/jj-commit
Command: npx skills add https://github.com/ahkohd/dotfiles --skill jj-commit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill creates conventional commit messages by analyzing diffs, running tests first, and handling immutable commits to streamline versioning.

Core Features & Use Cases

  • Test-first workflow: Detect and run tests before committing.
  • Context-aware messages: Derives type (feat, fix, refactor, docs, test, chore, style, perf) and scope from changes.
  • Immutable commit handling: Suggest --ignore-immutable if needed.
  • Use Case: Automate clean, consistent commit messages aligned with project conventions.

Quick Start

When ready to commit, trigger jj-commit to generate a conventional message after testing and diff analysis.

Frequently Asked Questions about jj-commit

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

FAQPage Schema
How do I generate conventional commit messages automatically from my JJ repository?

Conventional commit messages are generated by analyzing diffs and test results in your JJ project. This Skill detects the type of change (feat, fix, refactor, docs, test, chore, style, perf) and scope from your code modifications, then formats a standardized commit message before applying it to your immutable commits.

Can I run tests before committing in JJ projects?

Yes. This Skill discovers and runs tests first to validate changes, then generates the commit message based on both test results and diff analysis. This test-first workflow ensures only validated changes receive conventional commits.

What's the best way to keep commit messages consistent across a JJ repository?

Use conventional commits with automated message generation. This Skill derives commit type and scope from diffs contextually, ensuring every commit follows the conventional format (feat, fix, refactor, etc.) without manual formatting or inconsistency.

How does this handle immutable commits in JJ?

When a commit is immutable, the Skill suggests using the --ignore-immutable flag to proceed with the commit operation. This ensures your workflow continues smoothly while respecting JJ's immutability constraints.

Do I need to manually write commit messages if I use this Skill?

No. The Skill generates conventional commit messages automatically by analyzing your diffs and test results. You trigger it when ready to commit, and it handles type inference, scope detection, and message formatting end-to-end.

What information does the Skill use to determine commit type and scope?

The Skill analyzes diffs and log data to infer the commit type and scope. It examines what changed in your code to classify it as a feature, fix, refactor, documentation update, test, or style change, then applies the appropriate conventional commit format.