62 lines
2.0 KiB
Markdown
62 lines
2.0 KiB
Markdown
# /finish-up Skill Design
|
|
|
|
**Date:** 2026-02-23
|
|
|
|
## Purpose
|
|
|
|
A Claude Code slash command (`/finish-up`) that scans git projects for uncommitted changes and unpushed commits, reports findings, then autonomously commits and pushes selected projects via parallel subagents.
|
|
|
|
## Behavior
|
|
|
|
### Context Detection
|
|
|
|
- If CWD is `C:\Users\aisaacs\Desktop\Projects` (or not inside a git repo), scan all subdirectories
|
|
- If CWD is inside a specific project, scan just that project
|
|
|
|
### Phase 1 - Scan
|
|
|
|
Run a `git-status-check.sh` script from the Projects directory that:
|
|
- Checks each git repo for uncommitted changes (`git status --porcelain`)
|
|
- Checks for unpushed commits (`git log @{u}..HEAD --oneline`)
|
|
- Outputs structured results (project name, has uncommitted, has unpushed, file count, commit count)
|
|
|
|
This replaces the existing `check_uncommitted.py` with a bash script that also covers unpushed commits.
|
|
|
|
### Phase 2 - Report
|
|
|
|
Present findings as a summary:
|
|
- Projects with uncommitted changes (file counts)
|
|
- Projects with unpushed commits (commit counts)
|
|
- Clean projects (brief list)
|
|
- If everything clean, say so and exit
|
|
|
|
### Phase 3 - Confirm
|
|
|
|
Ask which projects to process (default: all that need attention).
|
|
|
|
### Phase 4 - Parallel Subagents
|
|
|
|
Spawn a Bash subagent per selected project. Each autonomously:
|
|
1. Stages all changes (`git add -A`)
|
|
2. Reviews the diff (`git diff --cached`)
|
|
3. Crafts a conventional commit message based on the changes
|
|
4. Commits
|
|
5. Pushes to remote (with retry for Gitea cold-start)
|
|
|
|
### Phase 5 - Summary
|
|
|
|
Report what was committed and pushed across all projects.
|
|
|
|
## Files
|
|
|
|
| File | Purpose |
|
|
|------|---------|
|
|
| `~/.claude/commands/finish-up.md` | Claude Code skill file |
|
|
| `~/Desktop/Projects/project-scripts/git-status-check.sh` | Scan script (replaces check_uncommitted.py) |
|
|
|
|
## Commit Message Style
|
|
|
|
Subagents craft conventional commit messages (feat/fix/chore/refactor/docs/etc.) with:
|
|
- Short summary line
|
|
- Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|