refactor: extract skills from commands across 8 plugins

Refactored commands to extract reusable skills following the
Commands → Skills separation pattern. Each command is now <50 lines
and references skill files for detailed knowledge.

Plugins refactored:
- claude-config-maintainer: 5 commands → 7 skills
- code-sentinel: 3 commands → 2 skills
- contract-validator: 5 commands → 6 skills
- data-platform: 10 commands → 6 skills
- doc-guardian: 5 commands → 6 skills (replaced nested dir)
- git-flow: 8 commands → 7 skills

Skills contain: workflows, validation rules, conventions,
reference data, tool documentation

Commands now contain: YAML frontmatter, agent assignment,
skills list, brief workflow steps, parameters

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-30 17:32:24 -05:00
parent aad02ef2d9
commit 7c8a20c804
71 changed files with 3896 additions and 3690 deletions

View File

@@ -1,124 +1,44 @@
---
name: branch-cleanup
description: Remove merged and stale branches locally and optionally on remote
agent: git-assistant
---
# /branch-cleanup - Clean Merged and Stale Branches
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Branch Cleanup │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the workflow.
- skills/visual-header.md
- skills/git-safety.md
- skills/sync-workflow.md
- skills/environment-variables.md
## Purpose
Remove branches that have been merged OR whose remote tracking branch no longer exists, both locally and optionally on remote.
Remove branches that have been merged OR whose remote tracking branch no longer exists.
## Behavior
## Parameters
### Step 1: Prune Remote Refs
| Parameter | Description |
|-----------|-------------|
| `--dry-run` | Preview without deleting |
| `--remote` | Also delete remote branches |
| `--stale-only` | Only delete stale branches (upstream gone) |
```bash
# Remove stale remote-tracking references
git fetch --prune
```
## Workflow
### Step 2: Identify Branches for Cleanup
```bash
# Find merged local branches
git branch --merged <base-branch>
# Find merged remote branches
git branch -r --merged <base-branch>
# Find local branches with deleted upstreams (stale)
git branch -vv | grep ': gone]'
```
### Step 3: Present Findings
```
Found branches for cleanup:
Merged (safe to delete):
- feat/login-page (merged 3 days ago)
- fix/typo-header (merged 1 week ago)
- chore/deps-update (merged 2 weeks ago)
Stale (remote deleted):
- feat/old-feature (upstream gone)
- fix/already-merged (upstream gone)
Remote (merged into base):
- origin/feat/login-page
- origin/fix/typo-header
Protected (won't delete):
- main
- development
- staging
Delete these branches?
1. Delete all (local merged + stale + remote)
2. Delete merged only (skip stale)
3. Delete stale only (upstream gone)
4. Let me pick which ones
5. Cancel
```
### Step 4: Execute Cleanup
```bash
# Delete merged local branches
git branch -d <branch-name>
# Delete stale local branches (force needed since no upstream)
git branch -D <stale-branch-name>
# Delete remote branches
git push origin --delete <branch-name>
```
### Step 5: Report
```
Cleanup complete:
Deleted local (merged): 3 branches
Deleted local (stale): 2 branches
Deleted remote: 2 branches
Skipped: 0 branches
Remaining local branches:
- main
- development
- feat/current-work (not merged, has upstream)
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `GIT_DEFAULT_BASE` | `development` | Base branch for merge detection |
| `GIT_PROTECTED_BRANCHES` | `main,master,development,staging,production` | Never delete these |
| `GIT_AUTO_DELETE_REMOTE` | `false` | Auto-delete remote branches |
| `GIT_CLEANUP_STALE` | `true` | Include stale branches (upstream gone) in cleanup |
## Safety
- Never deletes protected branches
- Warns about unmerged branches that still have upstreams
- Confirms before deleting remote branches
- Uses `-d` (safe delete) for merged branches
- Uses `-D` (force delete) only for stale branches with confirmation
- Stale branches are highlighted separately for review
1. **Display header** - Show GIT-FLOW Branch Cleanup header
2. **Prune remote refs** - `git fetch --prune`
3. **Find merged branches** - `git branch --merged <base-branch>`
4. **Find stale branches** - `git branch -vv | grep ': gone]'`
5. **Exclude protected** - Never delete protected branches (per git-safety.md)
6. **Present findings** - Show merged, stale, and protected lists
7. **Confirm deletion** - Options: all, merged only, stale only, pick, cancel
8. **Execute cleanup** - Delete selected branches
9. **Report** - Show deletion summary
## Output
On success:
```
Cleaned up:
Local (merged): 3 branches deleted

View File

@@ -1,106 +1,43 @@
---
name: branch-start
description: Create a new feature/fix/chore branch with consistent naming
agent: git-assistant
---
# /branch-start - Start New Branch
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Branch Start │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the workflow.
- skills/visual-header.md
- skills/branch-naming.md
- skills/git-safety.md
- skills/environment-variables.md
## Purpose
Create a new feature/fix/chore branch with consistent naming conventions.
Create a new branch with consistent naming conventions, based on the configured base branch.
## Usage
## Parameters
```
/branch-start [description]
```
| Parameter | Description |
|-----------|-------------|
| `<description>` | Brief description for branch name |
| `--type` | Branch type: feat, fix, chore, docs, refactor |
| `--issue` | Issue number to include in branch name |
## Behavior
## Workflow
### Step 1: Determine Branch Type
```
What type of change is this?
1. feat - New feature
2. fix - Bug fix
3. chore - Maintenance task
4. docs - Documentation
5. refactor - Code refactoring
```
### Step 2: Get Description
If not provided, ask:
```
Brief description (2-4 words):
> add user authentication
```
### Step 3: Generate Branch Name
Convert to kebab-case:
- `feat/add-user-authentication`
- `fix/login-timeout-error`
- `chore/update-dependencies`
### Step 4: Create Branch
```bash
# Ensure base branch is up-to-date
git checkout <base-branch>
git pull origin <base-branch>
# Create and switch to new branch
git checkout -b <new-branch>
```
### Step 5: Confirm
```
Created branch: feat/add-user-authentication
Based on: development (abc1234)
Ready to start coding!
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `GIT_DEFAULT_BASE` | `development` | Branch to create from |
| `GIT_BRANCH_PREFIX` | `true` | Use type/ prefix |
## Naming Rules
- Lowercase only
- Hyphens for spaces
- No special characters
- Max 50 characters
## Validation
```
Branch name validation:
✓ Lowercase
✓ Valid prefix (feat/)
✓ Descriptive (3+ words recommended)
✗ Too long (52 chars, max 50)
Suggested: feat/add-user-auth
Use this instead? (y/n)
```
1. **Display header** - Show GIT-FLOW Branch Start header
2. **Determine type** - Prompt for branch type if not provided
3. **Get description** - Prompt for description if not provided
4. **Generate name** - Convert to kebab-case (per branch-naming.md)
5. **Validate** - Check naming rules, truncate if needed
6. **Update base** - Checkout and pull base branch
7. **Create branch** - `git checkout -b <new-branch>`
8. **Confirm** - Display created branch info
## Output
On success:
```
Branch: feat/add-user-authentication
Base: development @ abc1234

View File

@@ -1,94 +1,49 @@
---
name: commit-merge
description: Commit current changes and merge branch into target
agent: git-assistant
---
# /commit-merge - Commit and Merge
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Commit & Merge │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the workflow.
- skills/visual-header.md
- skills/commit-conventions.md
- skills/merge-workflow.md
- skills/git-safety.md
- skills/environment-variables.md
## Purpose
Commit current changes, then merge the current branch into a target branch.
## Behavior
## Parameters
### Step 1: Run /commit
| Parameter | Description |
|-----------|-------------|
| `--target` | Target branch (default: GIT_DEFAULT_BASE) |
| `--squash` | Squash commits on merge |
| `--no-delete` | Keep branch after merge |
Execute the standard commit workflow.
## Workflow
### Step 2: Identify Target Branch
Check environment or ask:
```
Merge into which branch?
1. development (Recommended - GIT_DEFAULT_BASE)
2. main
3. Other: ____
```
### Step 3: Merge Strategy
```
How should I merge?
1. Merge commit (preserves history)
2. Squash and merge (single commit)
3. Rebase (linear history)
```
### Step 4: Execute Merge
```bash
# Switch to target
git checkout <target>
# Pull latest
git pull origin <target>
# Merge feature branch
git merge <feature-branch> [--squash] [--no-ff]
# Push
git push origin <target>
```
### Step 5: Cleanup (Optional)
```
Merge complete. Delete the feature branch?
1. Yes, delete local and remote (Recommended)
2. Delete local only
3. Keep the branch
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `GIT_DEFAULT_BASE` | `development` | Default branch to merge into |
| `GIT_MERGE_STRATEGY` | `merge` | Default merge strategy |
| `GIT_AUTO_DELETE_MERGED` | `true` | Auto-delete merged branches |
## Safety Checks
- Verify target branch exists
- Check for uncommitted changes before switching
- Ensure merge doesn't conflict (preview first)
1. **Display header** - Show GIT-FLOW Commit & Merge header
2. **Run /commit** - Execute standard commit workflow
3. **Identify target** - Prompt for target branch if not specified
4. **Select strategy** - Merge commit, squash, or rebase (per merge-workflow.md)
5. **Execute merge** - Switch to target, pull, merge, push
6. **Handle conflicts** - Guide resolution if needed
7. **Cleanup** - Offer to delete merged branch (per git-safety.md)
8. **Report** - Show merge summary
## Output
On success:
```
Committed: abc1234
feat(auth): add password reset functionality
Merged feat/password-reset development
Merged feat/password-reset -> development
Deleted branch: feat/password-reset
development is now at: def5678

View File

@@ -1,65 +1,42 @@
---
name: commit-push
description: Create a commit and push to remote in one operation
agent: git-assistant
---
# /commit-push - Commit and Push
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Commit & Push │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the workflow.
- skills/visual-header.md
- skills/commit-conventions.md
- skills/sync-workflow.md
- skills/git-safety.md
- skills/environment-variables.md
## Purpose
Create a commit and push to the remote repository in one operation.
## Behavior
## Parameters
### Step 1: Run /commit
| Parameter | Description |
|-----------|-------------|
| `--message`, `-m` | Override auto-generated message |
| `--force` | Force push (requires confirmation) |
Execute the standard commit workflow (see commit.md).
## Workflow
### Step 2: Push to Remote
After successful commit:
1. Check if branch has upstream tracking
2. If no upstream, set it: `git push -u origin <branch>`
3. If upstream exists: `git push`
### Step 3: Handle Conflicts
If push fails due to diverged history:
```
Remote has changes not in your local branch.
Options:
1. Pull and rebase, then push (Recommended)
2. Pull and merge, then push
3. Force push (⚠️ destructive)
4. Cancel and review manually
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `GIT_AUTO_PUSH` | `true` | Auto-push after commit |
| `GIT_PUSH_STRATEGY` | `rebase` | How to handle diverged branches |
## Safety Checks
- **Protected branches**: Warn before pushing to main/master/production
- **Force push**: Require explicit confirmation
- **No tracking**: Ask before creating new remote branch
1. **Display header** - Show GIT-FLOW Commit & Push header
2. **Run /commit** - Execute standard commit workflow
3. **Check upstream** - Set up tracking if needed (`git push -u`)
4. **Push** - Push to remote
5. **Handle conflicts** - Offer rebase/merge/force if push fails (per sync-workflow.md)
6. **Verify safety** - Warn before push to protected branches (per git-safety.md)
7. **Report** - Show push result
## Output
On success:
```
Committed: abc1234
feat(auth): add password reset functionality

View File

@@ -1,116 +1,49 @@
---
name: commit-sync
description: Commit, push, and sync with base branch
agent: git-assistant
---
# /commit-sync - Commit, Push, and Sync
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Commit Sync │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the workflow.
- skills/visual-header.md
- skills/commit-conventions.md
- skills/sync-workflow.md
- skills/merge-workflow.md
- skills/environment-variables.md
## Purpose
Full sync operation: commit local changes, push to remote, sync with upstream/base branch, and clean up stale remote-tracking branches.
Full sync operation: commit local changes, push to remote, sync with upstream/base branch, and detect stale branches.
## Behavior
## Parameters
### Step 1: Run /commit
| Parameter | Description |
|-----------|-------------|
| `--base` | Override default base branch |
| `--no-rebase` | Use merge instead of rebase |
Execute the standard commit workflow.
## Workflow
### Step 2: Push to Remote
Push committed changes to remote branch.
### Step 3: Sync with Base
Pull latest from base branch and rebase/merge:
```bash
# Fetch all with prune (removes stale remote-tracking refs)
git fetch --all --prune
# Rebase on base branch
git rebase origin/<base-branch>
# Push again (if rebased)
git push --force-with-lease
```
### Step 4: Detect Stale Local Branches
Check for local branches tracking deleted remotes:
```bash
# Find local branches with gone upstreams
git branch -vv | grep ': gone]'
```
If stale branches found, report them:
```
Stale local branches (remote deleted):
- feat/old-feature (was tracking origin/feat/old-feature)
- fix/merged-bugfix (was tracking origin/fix/merged-bugfix)
Run /branch-cleanup to remove these branches.
```
### Step 5: Report Status
```
Sync complete:
Local: feat/password-reset @ abc1234
Remote: origin/feat/password-reset @ abc1234
Base: development @ xyz7890 (synced)
Your branch is up-to-date with development.
No conflicts detected.
Cleanup:
Remote refs pruned: 2
Stale local branches: 2 (run /branch-cleanup to remove)
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `GIT_DEFAULT_BASE` | `development` | Branch to sync with |
| `GIT_SYNC_STRATEGY` | `rebase` | How to incorporate upstream changes |
| `GIT_AUTO_PRUNE` | `true` | Auto-prune stale remote refs on sync |
## Conflict Handling
If conflicts occur during rebase:
```
Conflicts detected while syncing with development.
Conflicting files:
- src/auth/login.ts
- src/auth/types.ts
Options:
1. Open conflict resolution (I'll guide you)
2. Abort sync (keep local state)
3. Accept all theirs (⚠️ loses your changes in conflicts)
4. Accept all ours (⚠️ ignores upstream in conflicts)
```
1. **Display header** - Show GIT-FLOW Commit Sync header
2. **Run /commit** - Execute standard commit workflow
3. **Push to remote** - Push committed changes
4. **Fetch with prune** - `git fetch --all --prune`
5. **Sync with base** - Rebase on base branch (per sync-workflow.md)
6. **Handle conflicts** - Guide resolution if conflicts occur (per merge-workflow.md)
7. **Push again** - `git push --force-with-lease` if rebased
8. **Detect stale** - Report stale local branches
9. **Report status** - Show sync summary
## Output
On success:
```
Committed: abc1234
Pushed to: origin/feat/password-reset
Synced with: development (xyz7890)
Status: Clean, up-to-date
Stale branches: None (or N found - run /branch-cleanup)
Stale branches: 2 found - run /branch-cleanup
```

View File

@@ -1,158 +1,41 @@
---
name: commit
description: Create a git commit with auto-generated conventional commit message
agent: git-assistant
---
# /commit - Smart Commit
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Smart Commit │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the commit workflow.
- skills/visual-header.md
- skills/git-safety.md
- skills/commit-conventions.md
- skills/environment-variables.md
## Purpose
Create a git commit with an auto-generated conventional commit message based on staged changes.
## Behavior
## Parameters
### Step 1: Check for Protected Branch
| Parameter | Description |
|-----------|-------------|
| `--message`, `-m` | Override auto-generated message |
| `--all`, `-a` | Stage all changes before commit |
Before any commit operation, check if the current branch is protected:
## Workflow
1. Get current branch: `git branch --show-current`
2. Check against `GIT_PROTECTED_BRANCHES` (default: `main,master,development,staging,production`)
If on a protected branch, warn the user:
```
⚠️ You are on a protected branch: development
Protected branches typically have push restrictions that will prevent
direct commits from being pushed to the remote.
Options:
1. Create a feature branch and continue (Recommended)
2. Continue on this branch anyway (may fail on push)
3. Cancel
```
**If option 1 (create feature branch):**
- Prompt for branch type (feat/fix/chore/docs/refactor)
- Prompt for brief description
- Create branch using `/branch-start` naming conventions
- Continue with commit on the new branch
**If option 2 (continue anyway):**
- Proceed with commit (user accepts risk of push rejection)
- Display reminder: "Remember: push may be rejected by remote protection rules"
### Step 2: Analyze Changes
1. Run `git status` to see staged and unstaged changes
2. Run `git diff --staged` to examine staged changes
3. If nothing staged, prompt user to stage changes
### Step 3: Generate Commit Message
Analyze the changes and generate a conventional commit message:
```
<type>(<scope>): <description>
[optional body]
[optional footer]
```
**Types:**
- `feat`: New feature
- `fix`: Bug fix
- `docs`: Documentation only
- `style`: Formatting, missing semicolons, etc.
- `refactor`: Code change that neither fixes a bug nor adds a feature
- `perf`: Performance improvement
- `test`: Adding/updating tests
- `chore`: Maintenance tasks
- `build`: Build system or external dependencies
- `ci`: CI configuration
**Scope:** Determined from changed files (e.g., `auth`, `api`, `ui`)
### Step 4: Confirm or Edit
Present the generated message:
```
Proposed commit message:
───────────────────────
feat(auth): add password reset functionality
Implement forgot password flow with email verification.
Includes rate limiting and token expiration.
───────────────────────
Options:
1. Use this message (Recommended)
2. Edit the message
3. Regenerate with different focus
4. Cancel
```
### Step 5: Execute Commit
If confirmed, run:
```bash
git commit -m "$(cat <<'EOF'
<message>
Co-Authored-By: Claude <noreply@anthropic.com>
EOF
)"
```
## Environment Variables
| Variable | Default | Description |
|----------|---------|-------------|
| `GIT_PROTECTED_BRANCHES` | `main,master,development,staging,production` | Branches that trigger protection warning |
| `GIT_COMMIT_STYLE` | `conventional` | Message style (conventional, simple, detailed) |
| `GIT_SIGN_COMMITS` | `false` | Use GPG signing |
| `GIT_CO_AUTHOR` | `true` | Include Claude co-author footer |
## Edge Cases
### No Changes Staged
```
No changes staged for commit.
Would you like to:
1. Stage all changes (`git add -A`)
2. Stage specific files (I'll help you choose)
3. Cancel
```
### Untracked Files
```
Found 3 untracked files:
- src/new-feature.ts
- tests/new-feature.test.ts
- docs/new-feature.md
Include these in the commit?
1. Yes, stage all (Recommended)
2. Let me pick which ones
3. No, commit only tracked files
```
1. **Display header** - Show GIT-FLOW Smart Commit header
2. **Check protected branch** - Warn if on protected branch (per git-safety.md)
3. **Analyze changes** - Run `git status` and `git diff --staged`
4. **Handle unstaged** - Prompt to stage if nothing staged
5. **Generate message** - Create conventional commit message (per commit-conventions.md)
6. **Confirm or edit** - Present message with options to use, edit, regenerate, or cancel
7. **Execute commit** - Run `git commit` with message and co-author footer
## Output
On success:
```
Committed: abc1234
feat(auth): add password reset functionality

View File

@@ -1,106 +1,50 @@
---
name: git-config
description: Configure git-flow settings for the current project
agent: git-assistant
---
# /git-config - Configure git-flow
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Configuration │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the configuration.
- skills/visual-header.md
- skills/environment-variables.md
- skills/workflow-patterns/branching-strategies.md
## Purpose
Configure git-flow settings for the current project.
Configure git-flow settings interactively or display current configuration.
## Behavior
## Parameters
### Interactive Configuration
| Parameter | Description |
|-----------|-------------|
| `--show` | Display current settings without prompting |
| `--reset` | Reset all settings to defaults |
| `<key>=<value>` | Set specific variable directly |
```
git-flow Configuration
═══════════════════════════════════════════
## Workflow
Current settings:
GIT_WORKFLOW_STYLE: feature-branch
GIT_DEFAULT_BASE: development
GIT_AUTO_DELETE_MERGED: true
GIT_AUTO_PUSH: false
1. **Display header** - Show GIT-FLOW Configuration header
2. **Load current settings** - Read from project and user config
3. **Present menu** - Show configuration options
4. **Handle selection** - Configure workflow style, base branch, protected branches, etc.
5. **Save settings** - Write to `.env` or `.claude/settings.json`
6. **Confirm** - Display saved configuration
What would you like to configure?
1. Workflow style
## Configuration Menu
1. Workflow style (simple, feature-branch, pr-required, trunk-based)
2. Default base branch
3. Auto-delete merged branches
4. Auto-push after commit
5. Protected branches
6. View all settings
7. Reset to defaults
```
### Setting: Workflow Style
```
Choose your workflow style:
1. simple
- Direct commits to development
- No feature branches required
- Good for solo projects
2. feature-branch (Recommended)
- Feature branches from development
- Merge when complete
- Good for small teams
3. pr-required
- Feature branches from development
- Requires PR for merge
- Good for code review workflows
4. trunk-based
- Short-lived branches
- Frequent integration
- Good for CI/CD heavy workflows
```
### Setting: Protected Branches
```
Protected branches (comma-separated):
Current: main, master, development, staging, production
These branches will:
- Never be auto-deleted
- Require confirmation before direct commits
- Warn before force push
```
## Environment Variables
| Variable | Default | Options |
|----------|---------|---------|
| `GIT_WORKFLOW_STYLE` | `feature-branch` | simple, feature-branch, pr-required, trunk-based |
| `GIT_DEFAULT_BASE` | `development` | Any branch name |
| `GIT_AUTO_DELETE_MERGED` | `true` | true, false |
| `GIT_AUTO_PUSH` | `false` | true, false |
| `GIT_PROTECTED_BRANCHES` | `main,master,development,staging,production` | Comma-separated |
| `GIT_COMMIT_STYLE` | `conventional` | conventional, simple, detailed |
| `GIT_CO_AUTHOR` | `true` | true, false |
## Storage
Settings are stored in:
- Project: `.env` or `.claude/settings.json`
- User: `~/.config/claude/git-flow.env`
Project settings override user settings.
## Output
After configuration:
```
Configuration saved!

View File

@@ -1,84 +1,56 @@
---
name: git-status
description: Show comprehensive git status with recommendations
agent: git-assistant
---
# /git-status - Enhanced Status
## Visual Output
## Skills
When executing this command, display the plugin header:
```
┌──────────────────────────────────────────────────────────────────┐
│ 🔀 GIT-FLOW · Status │
└──────────────────────────────────────────────────────────────────┘
```
Then proceed with the status display.
- skills/visual-header.md
- skills/commit-conventions.md
- skills/environment-variables.md
## Purpose
Show comprehensive git status with recommendations and insights.
Show comprehensive git status with recommendations and insights beyond standard `git status`.
## Behavior
## Parameters
### Output Format
| Parameter | Description |
|-----------|-------------|
| `--short` | Compact output format |
## Workflow
1. **Display header** - Show GIT-FLOW Status header
2. **Gather info** - Branch, base comparison, remote status
3. **Categorize changes** - Staged, unstaged, untracked, deleted, renamed
4. **Generate recommendations** - What to stage, commit, sync
5. **Show quick actions** - Relevant /commands for current state
## Output Format
```
═══════════════════════════════════════════
Git Status: <repo-name>
═══════════════════════════════════════════
Branch: feat/password-reset
Base: development (3 commits ahead, 0 behind)
Remote: origin/feat/password-reset (synced)
─── Changes ───────────────────────────────
--- Changes ---
Staged (ready to commit):
src/auth/reset.ts (modified)
✓ src/auth/types.ts (modified)
[x] src/auth/reset.ts (modified)
Unstaged:
tests/auth.test.ts (modified)
• src/utils/email.ts (new file, untracked)
─── Recommendations ───────────────────────
[ ] tests/auth.test.ts (modified)
--- Recommendations ---
1. Stage test file: git add tests/auth.test.ts
2. Consider adding new file: git add src/utils/email.ts
3. Ready to commit with 2 staged files
2. Ready to commit with 1 staged file
─── Quick Actions ─────────────────────────
/commit - Commit staged changes
• /commit-push - Commit and push
• /commit-sync - Full sync with development
═══════════════════════════════════════════
--- Quick Actions ---
/commit - Commit staged changes
/commit-push - Commit and push
```
## Analysis Provided
### Branch Health
- Commits ahead/behind base branch
- Sync status with remote
- Age of branch
### Change Categories
- Staged (ready to commit)
- Modified (not staged)
- Untracked (new files)
- Deleted
- Renamed
### Recommendations
- What to stage
- What to ignore
- When to commit
- When to sync
### Warnings
- Large number of changes (consider splitting)
- Old branch (consider rebasing)
- Conflicts with upstream
## Output
Always produces the formatted status report with context-aware recommendations.