git-conventions

Enforce branch, commit, and pull request naming conventions for Git workflows.

1|1|Updated Jun 11, 2024
One-click install
npx skills add https://github.com/ag-grid/ag-shared --skill git-conventions-ag-grid
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: git-conventions
Source: https://github.com/ag-grid/ag-shared/tree/main/prompts/skills/git-conventions
Command: npx skills add https://github.com/ag-grid/ag-shared --skill git-conventions-ag-grid

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Git conventions help teams standardize how branches, commits, and pull requests are created and described, reducing ambiguity and review time.

Core Features & Use Cases

  • Branch naming rules:
    • JIRA-linked: ag-xxxxx/<descriptive-slug> (lowercase JIRA number, kebab-case slug)
    • No JIRA: <initials>/<descriptive-slug> (author initials, kebab-case slug)
    • Release: b12.0.0 (see Releases guide)
  • Commit message guidelines:
    • JIRA-linked first line: AG-XXXX <description> (uppercase JIRA number)
    • No JIRA: <description> (concise, imperative mood)
    • Keep the first line under 72 characters.
    • Never attribute agentic tooling (no "Co-authored-by", "Generated by", or similar).
  • Pull Requests:
    • Title: JIRA-linked: AG-XXXX <description> (match commit style, under 70 characters)
    • Body: include link(s) to the JIRA ticket(s) as the body; No JIRA: concise description of the change.
  • Note: Follow these conventions consistently to improve code review speed and traceability.

Quick Start

Follow these conventions in your next feature branch, commit, and pull request to ensure consistency.

Frequently Asked Questions about git-conventions

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

FAQPage Schema
How do I name a git branch with a JIRA ticket number?

For a git branch without a JIRA ticket, use the pattern <initials>/<descriptive-slug> with the author's initials and a kebab-case slug. This maintains team workflow consistency when tickets are absent.

What is the best way to format git commit messages for team workflows?

The best way to format git commit messages is using an imperative mood with the first line under 72 characters. For JIRA-linked commits, start with an uppercase AG-XXXX followed by a concise description to improve review speed.

How do I structure a pull request title and body for a JIRA-linked branch?

To structure a pull request, match the commit style in the title with an uppercase AG-XXXX and description under 70 characters. The body should include direct links to the JIRA tickets for clear traceability during code review.

Should I attribute AI tooling in git commit messages?

You should never attribute agentic tooling in git commit messages. Avoid adding phrases like "Co-authored-by" or "Generated by" to maintain clean, consistent commit histories across team workflows.

What naming conventions should I use for a git release branch?

For git release branches, you should use a direct release naming pattern like b12.0.0. This aligns with standard release guides and keeps release tracks unambiguous within the repository.