| name | git-workflow |
| description | | Use when this capability is needed. |
Git Workflow
Automate git operations with Conventional Commits, auto-push, and PR creation.
Core Principles
- One commit per logical unit: don't mix unrelated changes in one commit
- Conventional Commits format:
type(scope): description
- Auto-push after commit: push to remote by default (configurable)
- Safety first: check for unresolved conflicts before push
Commands
/save
Lightweight WIP commit for in-progress work. Does not push.
git add -A
- Analyze the diff to generate a short description
git commit -m "wip: {auto-generated description}"
- Do NOT push (WIP commits stay local)
/commit [message]
Formal commit after completing a logical unit of work.
git add -A
- Analyze
git diff --staged:
- Run the generate-commit-msg.sh script from the plugin's scripts/ directory to get structured diff info
- Or directly analyze
git diff --staged --stat and git diff --staged
- Determine Conventional Commit components:
- type: feat | fix | refactor | docs | test | chore | perf | ci | build
- scope: infer from changed file paths (e.g.,
auth, api, ui)
- description: concise summary of the change
- If user provided a message, use it as the commit body
- Format:
git commit -m "{type}({scope}): {description}" -m "{body}"
- Body includes a change summary
- Auto-push:
git push origin {current-branch}
- If push fails (remote has new commits):
git pull --rebase then retry push
/push
Manual push trigger (when auto-push is disabled).
- Check for uncommitted changes → prompt user to
/commit first
git push origin {current-branch}
- If new branch, auto-add
--set-upstream
- If remote conflicts, inform user and suggest resolution
/pr [title]
Create a Pull Request.
- Ensure all local commits are pushed (run
/push if needed)
- Collect all commit messages on this branch relative to base
- Generate PR description:
- Change summary (from commits)
- Reference to plan file (if in
./plans/)
- If synapse-ears is installed, EARS key findings (if in
traces/)
- Run:
gh pr create --title "{title}" --body "{description}"
- If no title provided, generate from branch name
- If vibe-kanban task exists, add reference in PR description
/squash-merge
Merge an approved PR and clean up.
gh pr merge --squash
- If synapse-worktree is installed, run
/worktree cleanup for the corresponding worktree
- If synapse-ears is installed, check if any EARS entries from this branch should be promoted to KNOWN_ISSUES.md
Conventional Commits Reference
| Type | Use When |
|---|
| feat | New feature or capability |
| fix | Bug fix |
| refactor | Code restructuring without behavior change |
| docs | Documentation only |
| test | Adding or updating tests |
| chore | Maintenance (deps, config, CI) |
| perf | Performance improvement |
| ci | CI/CD changes |
| build | Build system changes |
Auto-Commit Triggers (from companion plugins)
These triggers come from companion plugins if installed:
- synapse-execute: plan-execute completes a batch and passes code-review
- synapse-review: plan-review completes a revision round
- synapse-worktree: worktree handoff (before handoff)
EARS Integration (requires synapse-ears)
If synapse-ears is installed:
- After important commits, write an EARS Checkpoint if warranted
- The EARS PostToolUse hook (ears-trace.py) continues to work independently
- On
/squash-merge, check traces/ for patterns worth promoting to KNOWN_ISSUES.md
- ears-trace.py detects errors in Bash output → triggers EARS Error prompt
If synapse-ears is NOT installed, skip EARS entries.
Source: CHOSENX-GPU/synapse — distributed by TomeVault.