Commit
Generate a Conventional Commits message, commit, and optionally push to remote.From its SKILL.md
npx -y skills add yagizdo/quiver --skill commitAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 11 stars11 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
6.5 KB, as published. Nobody here has run it
Gather Git Context
!`git rev-parse --is-inside-work-tree 2>/dev/null || echo "NO_GIT"`
!`git status --short 2>/dev/null || echo "NO_GIT"`
!`git diff --cached 2>/dev/null || echo "NO_GIT"`
!`git log --oneline -10 2>/dev/null || echo "NO_GIT"`
Instructions
Step 0 -- Git Availability
If any gather-context block above returned NO_GIT, this directory is not a git repository.
Print: > No git repository detected. /commit requires a git repo.
Stop here.
Silently determine which case applies — do not show the case label or decision logic to the user:
- No changes: If
git statusis empty → tell the user and stop. - Nothing staged: If
git diff --cachedis empty butgit statusshows changes → tell the user to stage files and run/quiver:commitagain, then stop. - Staged changes exist: Proceed silently to Commit Message Generation.
Commit Message Generation
Analyze git diff --cached and the recent log. Generate a Conventional Commits message following these rules:
Type — Select one based on primary intent:
| Type | When to Use |
|---|---|
feat | New feature or capability visible to users |
fix | Bug fix |
docs | Documentation only (README, comments, JSDoc) |
style | Formatting, whitespace, semicolons — no logic change |
refactor | Code restructuring with no behavior change |
perf | Performance improvement |
test | Adding or fixing tests |
build | Build system or external dependencies (npm, Makefile) |
ci | CI/CD configuration (GitHub Actions, CircleCI) |
chore | Maintenance tasks (version bumps, tooling config) |
revert | Reverting a previous commit |
Scope — From file paths: single directory → its name, single file → domain name, cross-cutting → omit.
Breaking changes — If the change removes/renames public APIs, changes signatures, alters data formats, or removes CLI flags/commands, add ! after type/scope and a BREAKING CHANGE: footer.
Subject line — Imperative mood, lowercase after colon, no period, ≤72 chars total, describe what not how.
Body — Almost never. Only for breaking changes or when the subject alone would be misleading. Wrap at 72 chars. Never include file lists — git log --stat shows this.
Footers — BREAKING CHANGE: if applicable. Refs: #issue if relevant.
Output
Important: Do NOT output the commit message as separate text. Embed it directly inside the AskUserQuestion tool call so the user always sees the message alongside the options.
Include a body or footers only for breaking changes or multi-type changes where the subject alone is genuinely ambiguous. Default to subject-only. Don't add Co-authored-by or attribution footers unless explicitly requested.
Flag: --push
If $ARGUMENTS contains "push" (e.g., /quiver:commit --push), skip the AskUserQuestion step entirely. Instead, show the generated commit message, then immediately execute Commit & Push (commit + push to remote) without prompting.
Default (no flag)
Use the AskUserQuestion tool with the commit message embedded in the question field:
- Question: Build the question string using this template (replace placeholders):\
"\x1b[2mCommit Message:\x1b[0m\n\n{type}({scope}): {subject}\n\nProceed?"
If the message has a body, append body lines after the subject separated by newlines.
- Header: "Action"
- Options:
- Commit — "Commit with this message"
- Commit & Push — "Commit and push to remote"
- Edit — "Revise the message"
- Cancel — "Abort without committing"
Commit Execution
On commit or commit & push:
- Commit using a HEREDOC:
git commit -m "$(cat <<'EOF' {full commit message} EOF )" - Verify:
git log --oneline -1andgit status --short.
If commit & push, also:
- Detect branch:
git branch --show-current - Push: if
git rev-parse --abbrev-ref @{upstream} 2>/dev/nullsucceeds →git push, otherwise →git push -u origin {branch} - Verify push exit code is 0.
Output:
Committed:
{short hash}{subject} Branch:{branch name}Pushed to:origin/{branch}(only if pushed)
On edit: Ask what to change, revise, re-present, and ask again.
On cancel:
Commit cancelled. Staged changes are intact.
Stop here.
Error Handling
If git commit fails, show the error verbatim and suggest the user fix the issue and re-run /quiver:commit. Never retry automatically or use --no-verify.
Test Plan
Trigger: /commit or /commit --push (and /quiver:commit should also work)
Setup:
- Current directory is a git repo with at least one staged change (
git diff --cachedis non-empty).
Expected behavior:
- Skill runs the four git shell blocks; on a non-git directory it prints
> No git repository detected. /commit requires a git repo.and stops. - With nothing changed, skill tells the user there's nothing to commit. With unstaged-only changes, skill tells the user to stage first.
- With staged changes, skill drafts a Conventional Commits message (type/scope/subject) and presents it via
AskUserQuestionwithCommit / Commit & Push / Edit / Cancel. - With
--pushargument, skill skips the prompt and runs commit then push (git pushif upstream exists,git push -u origin <branch>otherwise). - On failure, skill shows the error verbatim and exits without retrying or adding
--no-verify.
Verification checklist:
- Slash menu shows
/commit. - Generated commit message starts with a valid type (
feat,fix,docs, etc.) and a subject ≤72 chars. - No
Co-authored-byor AI-attribution footers appear in the commit. - The interactive prompt is an
AskUserQuestionwith the message embedded in the question, not plain text. -
--pushpath commits and pushes without prompting.
Known gotchas:
- The
\x1b[2mANSI dim escape inside the question string assumes the user's terminal renders ANSI; non-ANSI terminals will see literal escape codes but the message remains readable. - Pushing without an upstream requires
git push -u origin <branch>; do not silently fall back togit pushwhen no upstream is configured.