mcpField
A
atomic-commits

atomic-commits

github.com/nullswanDevelopment0160 installsUpdated 39w ago
Repository

About atomic-commits

atomic-commits is a skill for developers organizing a set of Git changes into independently reviewable commits. It guides change analysis, logical grouping, incremental staging, commit ordering, and verification.

Key features

  1. 01Inspect Git status and diffs
  2. 02Group changes by type
  3. 03Stage and commit changes incrementally
  4. 04Order commits by risk and purpose
  5. 05Verify history before pushing

Use cases

  1. 01Separate unrelated changes before review
  2. 02Prepare a readable history from a mixed diff
  3. 03Stage only part of a file with git add -p

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/nullswan/atomic-commits --skill atomic-commits

After installing, type/atomic-commitsin Claude Code to confirm it loaded.

Bundled filesreferences/advanced.md

Details

From the project README

Atomic Commits

Organize multiple git changes into clean, atomic commits that maintain a proper git history.

Workflow

1. Analyze Changes
git status
git diff --stat
git diff
2. Group Changes Logically

Categorize by type:

  • feat: New features
  • fix: Bug fixes
  • refactor: Code improvements
  • docs: Documentation
  • test: Test changes
  • chore: Maintenance
3. Commit Incrementally

Stage specific files for each logical commit:

git add path/to/related/files
git commit -m "feat: add user authentication"

git add path/to/other/files
git commit -m "fix: correct null check in validator"
4. Push
git log --oneline -10  # Verify commits
git push origin <branch>

Commit Order

  1. Documentation (lowest risk)
  2. Tests (verification setup)
  3. Bug fixes (independent corrections)
  4. Features (main changes)
  5. Refactoring (improvements)

Commit Message Format

<type>(<scope>): <description>

[optional body]

Types: feat, fix, docs, style, refactor, test, chore

Example

Given changes to login page, avatar fix, README update, and new tests:

git add README.md
git commit -m "docs: update README with login instructions"

git add tests/login.test.ts
git commit -m "test: add login component tests"

git add src/components/Avatar.tsx
git commit -m "fix: correct avatar display on retina screens"

git add src/pages/Login.tsx src/components/LoginForm.tsx
git commit -m "feat: add login page with validation"

git push origin feature/login

Tips

  • Each commit should be independently reviewable
  • Each commit should leave codebase in working state
  • When in doubt, prefer more commits over fewer
  • Use git add -p for interactive staging of partial files

See references/advanced.md for advanced patterns.

Comments

Markdown supported