Skip to content
Back to skills

Add Commit

ASecurity

Knowledge reference for smart mid-workflow commits: adaptive Conventional Commits message logic, type detection, and staging rules.

  • 11 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 29, 2026
developmentbashgitfrontendbackenddocumentation

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned November 18, 2026

npx -y skills add brabos-ai/code-addiction --skill add--commit --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Add Commit?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Add  Commit
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/brabos-ai-add-commit/badge)](https://www.skillsdirectory.com/skills/brabos-ai-add-commit)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: add--commit
description: "Knowledge reference for smart mid-workflow commits: adaptive Conventional Commits message logic, type detection, and staging rules."
---

# add--commit — Smart Commit

<!-- uses:
- command: /add-build (conditional)
- mention: /add-done
- mention: /add-pull-request
- script: converge-gates.cjs
- skill: add--doc-schemas
-->

## When to Use

- Mid-workflow commits during feature development
- Saving progress checkpoints before risky changes
- Any `git commit` with automatic message generation
- Quick commits with optional `--push` in one step

## When NOT to Use

- **Finalizing a branch** → use `/add-done` instead
- **Creating or updating a PR** → use `/add-pull-request`
- **Force push, rebase, or amend** → out of scope
- **Specific file staging** → stage manually first, then use the command

---

## Adaptive Message Logic

The message format adapts to changeset size:

**≤ 3 files changed** — single-line message:
```
type(scope): objective description in present tense
```

**> 3 files changed** — list format:
```
type: general summary

- context/module: what changed
- context/module: what changed
- context/module: what changed
```

---

## Conventional Commits Type Detection

Infer the type from the diff content:

| Type | When to use |
|------|-------------|
| `feat` | New feature, new functionality |
| `fix` | Bug fix, error correction |
| `refactor` | Code restructure without behavior change |
| `chore` | Config, deps, scripts, tooling |
| `docs` | Documentation only |
| `test` | Test files only |
| `style` | Formatting, whitespace, lint fixes |

When ambiguous, show the inferred type and ask the user to confirm.

---

## Staging Rules

A code commit stages **code only**. Docs live on the `codeadd-docs` branch, a separate worktree the code branch ignores, so a doc can never enter a code commit and is saved by the end-of-command rule in `add--doc-schemas` → Docs Branch, never by staging.

```bash
git add -A
```

---

## Checkpoint Receipt (epic checkpoints only)

A commit made by `{{cmd:add-build}}`'s Checkpoint Sequence at a subfeature
boundary carries the convergence result as a **trailer**, so the checkpoint says
why it was safe to stop there. The commit hash then points at the work AND at
the proof.

The commit carries **the six gate lines** — `GATE_REVIEW`, `GATE_QA_BASELINE`,
`GATE_EPIC`, `GATE_COVERAGE`, `GATE_LEDGER`, `GATES_OK` — **copied verbatim** from
`converge-gates.cjs`'s output, as **body lines** below the Conventional Commits
body. The script emits more keys than these (`REVIEW_PATH`, `BASELINE`,
`EPIC_PENDING`, `COVERAGE_UNCOVERED`, `QA_FEATURE_STATE`); only the six above
belong in the message.

They are **body lines, not git trailers.** `GATE_REVIEW=ok` has no `Key: value`
colon, so `git interpret-trailers` will never parse it — calling them trailers
would promise tooling behaviour that does not exist. `git log --grep=GATES_OK`
works on body lines, which is the only retrieval this needs:

```
feat(0028F-SF02): persist receipt line total on duplicate

- backend: enforce RN03 on the duplicate path
- frontend: surface the persisted total in the header

GATE_REVIEW=ok
GATE_QA_BASELINE=ok
GATE_EPIC=ok
GATE_COVERAGE=ok
GATE_LEDGER=ok
GATES_OK=5/5
```

⛔ DO NOT reformat, summarise, or re-word the gate lines. They are copied, not
authored — a reformatted receipt is indistinguishable from an invented one, and
the whole point is that `git log --grep=GATES_OK` reconstructs which
subfeatures converged and on what evidence, using nothing but git.

⛔ DO NOT write these lines on a commit whose subfeature did not converge. That
commit does not exist: the checkpoint is gated on all five gates reading `ok`,
and the ABSENCE of a commit is itself the signal.

**No new state file.** The receipt lives in the commit message, so it adds no
state file — a commit message is not a second source of truth that can drift
from the tree, it is part of the object that carries the tree.

---

## Examples

**Few files (≤ 3):**
```
feat(auth): add JWT refresh token endpoint
```

**Many files (> 3):**
```
refactor: extract service layer from controllers

- auth: move login/register logic to AuthService
- user: extract UserService from UserController
- order: decouple OrderService dependencies
- shared: add BaseService abstract class
```

Files in this skill

  • SKILL.md4.6 KB
  • evals/evals.json1.4 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.