tyrealq/q-skills

commit

Stage and commit uncommitted changes with conventional commit messages. Use for committing changes or grouping commits by topic.

First seen Mar 30, 2026

Installation

$ npx skills add tyrealq/q-skills --skill commit

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from tyrealq/q-skills · top by installs.

npx skills add tyrealq/q-skills

Browse all from tyrealq/q-skills

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Repository health

Stars 108
License LICENSE
Default branch main
Open issues 0
Status Active

Skill metadata

Parsed from SKILL.md frontmatter.

Declared agents claude-code

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 4,648 B
  • docs SUMMARY.md 142 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 6 installs

SKILL.md

Git Commit Skill

Stages and commits uncommitted changes with conventional commit messages. Groups files by topic when multiple unrelated changes are pending, runs cascade and CLAUDE.md freshness checks, and sweeps temp files after each commit. Does not push — hand off to /ship for that.

Workflow

Step 1: Review changes

Run both commands to get the full picture:

git status --short
git diff --cached --name-status

git status --short shows unstaged modifications and untracked files. git diff --cached catches files that are already staged but not yet committed. Use the union of both outputs.

If both commands return empty, report "nothing to commit" and stop.

Classify each change:

  • M — modified, ?? — untracked, D — deleted, R — renamed, A — staged new file

Step 2: Analyze changes and verify consistency

Classify file paths

Path pattern Type
posts/, articles/, content/ content/writing
.claude/skills/ skill config
src/, .go, .py, .ts, .R, *.r code/scripts
*.md documentation
.json, .yaml, .toml, .csv config/data

Cascade check (skip if no scripts or data files changed)

If any modified files are scripts or data files:

  • Identify downstream files: Find all markdown reports, appendices, and documentation that reference outputs or data from the modified files — search for filename references, table headers, variable names, and output patterns
  • Verify consistency: Check that numbers, table data, file paths, and cross-references in downstream files match the current state of the modified scripts and their outputs
  • Fix discrepancies: Update any stale numbers, outdated references, or mismatched data in downstream files. Include these fixes in the commit

CLAUDE.md freshness (always run)

If the working directory has a CLAUDE.md, read it and compare against the current project state — not just the changes being committed, but also decisions made during the session, new or renamed files on disk, and structural changes. Update CLAUDE.md before proceeding if any section reflects outdated state.

Step 3: Decide commit strategy

  • Single topic: one commit for all files
  • Multiple topics: group by directory/topic, one commit per group

Grouping priority:

  1. Content (one commit per article/document unit)
  2. Skills (one commit per skill)
  3. Code changes (group by module)
  4. Config files (group together)

Step 4: Generate commit message

Follow conventional commits format from rules/git-workflow.md:

<type>: <description>

Types: feat, fix, refactor, docs, test, chore, perf, ci

Examples:

  • docs: add exploratory analysis notebook
  • feat: add batch processing to pipeline
  • fix: correct citation formatting in report
  • chore: update project config

Keep descriptions concise (under 70 chars).

Step 5: Stage and commit

git add <file1> <file2> ...
git commit -m "<message>"

Rules:

  • Specify files explicitly — never use git add . or git add -A
  • Exclude temp files (.bak-, .DSStore, nodemodules/)
  • Exclude test scaffolding (tests/, test_*.py) from repos that ship as shared/public artifacts unless the user asks to include it

Step 6: Cleanup temp files

After the commit succeeds, remove these patterns from the working tree (skip .git/):

  • Files: .bak-, .pyc, .pyo, .swp, .swo, *~, .DS_Store, Thumbs.db
  • Directories: pycache/, .pytestcache/, .mypycache/, .ruff_cache/

List matches first, then delete. If nothing matches, note "no temp files to clean" and proceed.

find . -not -path '*/.git/*' -type f \( -name '*.bak-*' -o -name '*.pyc' -o -name '*.pyo' -o -name '*.swp' -o -name '*.swo' -o -name '*~' -o -name '.DS_Store' -o -name 'Thumbs.db' \) -print -exec rm -f {} +
find . -not -path '*/.git/*' -type d \( -name '__pycache__' -o -name '.pytest_cache' -o -name '.mypy_cache' -o -name '.ruff_cache' \) -print -exec rm -rf {} +

Step 7: Confirm

Run: git log --oneline -3

Checklist

  • All modified files reviewed and classified
  • Cascade check completed for script/data changes
  • CLAUDE.md updated if project structure or dependencies changed
  • Commit message follows conventional commits format
  • No temp files or sensitive files staged
  • Commit completed successfully
  • Temp files cleaned after commit