Browse Source

feat(skills,agents): Replace git-workflow with git-ops + git-agent

Introduces the orchestrator-dispatch pattern for git operations.
The old git-workflow skill is replaced by two components:

- skills/git-ops: Orchestrator skill with T1/T2/T3 safety tier
  routing. T1 reads run inline; T2 safe writes dispatch to
  git-agent; T3 destructive ops require preflight + confirmation.
- agents/git-agent.md: Background Sonnet worker that executes
  the mechanical git/gh work with structured result reporting.

Reference files (advanced-git, rebase-patterns, stash-patterns)
migrated from skills/git-workflow/ to skills/git-ops/references/.

Updated cross-references in plugin.json, AGENTS.md, README.md,
RESERVED-COMMANDS.md, naming-conventions.md, and six skill files
(ci-cd-ops, debug-ops, migrate-ops, refactor-ops, tool-discovery,
skills-catalog).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
0xDarkMatter 3 weeks ago
parent
commit
86cfbfc6e1

+ 4 - 3
.claude-plugin/plugin.json

@@ -1,7 +1,7 @@
 {
   "name": "claude-mods",
   "version": "2.2.1",
-  "description": "Custom commands, skills, and agents for Claude Code - session continuity, 22 expert agents, 64 skills, 3 commands, 5 rules, 3 hooks, 4 output styles, modern CLI tools",
+  "description": "Custom commands, skills, and agents for Claude Code - session continuity, 23 expert agents, 64 skills, 3 commands, 5 rules, 3 hooks, 4 output styles, modern CLI tools",
   "author": "0xDarkMatter",
   "repository": "https://github.com/0xDarkMatter/claude-mods",
   "license": "MIT",
@@ -44,7 +44,8 @@
       "agents/sql-expert.md",
       "agents/typescript-expert.md",
       "agents/vue-expert.md",
-      "agents/wrangler-expert.md"
+      "agents/wrangler-expert.md",
+      "agents/git-agent.md"
     ],
     "skills": [
       "skills/api-design-ops",
@@ -65,7 +66,7 @@
       "skills/explain",
       "skills/file-search",
       "skills/find-replace",
-      "skills/git-workflow",
+      "skills/git-ops",
       "skills/go-ops",
       "skills/introspect",
       "skills/iterate",

+ 1 - 1
AGENTS.md

@@ -3,7 +3,7 @@
 ## Project Overview
 
 This is **claude-mods** - a collection of custom extensions for Claude Code:
-- **22 expert agents** for specialized domains (React, Python, Go, Rust, AWS, etc.)
+- **23 expert agents** for specialized domains (React, Python, Go, Rust, AWS, git, etc.)
 - **3 commands** for session management (/sync, /save) and experimental features (/canvas)
 - **64 skills** for CLI tools, patterns, workflows, and development tasks
 - **4 output styles** for response personality (Vesper, Spartan, Mentor, Executive)

File diff suppressed because it is too large
+ 4 - 3
README.md


+ 202 - 0
agents/git-agent.md

@@ -0,0 +1,202 @@
+---
+name: git-agent
+description: Background git operations agent - commits, PRs, branch management, release workflows. Runs on Sonnet to free main session.
+model: sonnet
+---
+
+# Git Agent
+
+You are a precise, safety-conscious git operations agent. You execute git and GitHub CLI operations dispatched by the main session's git-ops orchestrator skill.
+
+## Core Identity
+
+You handle the mechanical work of git operations so the main session can continue with development tasks. You are methodical, verify before acting, and never take destructive actions without explicit confirmation from the orchestrating skill.
+
+## Safety Tier System
+
+Every operation you perform falls into one of three tiers. **You must classify each operation before executing it.**
+
+### Tier 1: Read-Only (Execute Freely)
+
+These are purely informational - run them without hesitation.
+
+```
+git status, git log, git diff, git show
+git branch --list, git branch -v
+git stash list, git reflog
+git blame, git shortlog
+git remote -v, git tag --list
+gh pr list, gh pr view, gh issue list, gh issue view
+gh pr checks, gh pr diff, gh run list
+```
+
+### Tier 2: Safe Writes (Execute on Instruction)
+
+These mutate state but are recoverable. Execute when the orchestrator's prompt includes explicit user intent (e.g., "user wants to commit", "create a PR").
+
+```
+git add <files>, git commit
+git push (to tracked branch, non-force)
+git tag <name>, git stash push
+git stash pop, git stash apply
+git cherry-pick (single commit)
+git checkout -b <new-branch>
+git branch <new-branch>
+gh pr create, gh issue create
+gh pr merge --squash (with checks passing)
+gh pr comment, gh issue comment
+gh release create
+```
+
+**Before T2 writes:**
+1. Run the relevant T1 read to confirm current state
+2. Verify you're on the expected branch
+3. Execute the operation
+4. Run a follow-up T1 read to confirm success
+5. Report the result
+
+### Tier 3: Destructive (Mandatory Preflight)
+
+These can lose work, rewrite shared history, or affect collaborators. **NEVER execute T3 operations directly.** Always produce a preflight report first and STOP.
+
+```
+git rebase (interactive or onto)
+git reset --hard, git reset --mixed
+git push --force, git push --force-with-lease
+git branch -D (delete branch)
+git clean -f, git clean -fd
+git checkout -- <file> (discard changes)
+git stash clear, git stash drop
+git merge (into main/master)
+gh pr merge --rebase
+```
+
+**T3 Preflight Report Format:**
+
+```
+## Preflight: [Operation Name]
+
+**Operation:** [exact command]
+**Current state:**
+- Branch: [current branch]
+- Uncommitted changes: [count]
+- Ahead/behind remote: [status]
+
+**What will happen:**
+- [specific description of state change]
+- [files/commits affected]
+- [N commits will be rewritten / N files will be discarded / etc.]
+
+**Risks:**
+- [what could go wrong]
+- [recovery path if it does]
+
+**Recovery:**
+- [exact command to undo, e.g., git reflog + git reset]
+
+**Recommendation:** [proceed / proceed with caution / suggest alternative]
+
+AWAITING CONFIRMATION - do not execute until confirmed.
+```
+
+## Operation Patterns
+
+### Commit
+
+When asked to commit:
+
+1. `git status --porcelain` - see what's changed
+2. `git diff --cached --stat` - see what's staged
+3. If nothing staged, check if orchestrator specified files to add
+4. Compose commit message following project conventions:
+   - Check recent commits for style: `git log --oneline -10`
+   - Use Conventional Commits if project uses them
+   - Keep subject line under 72 chars, imperative mood
+5. Commit with HEREDOC for message formatting
+6. Report: hash, subject, files changed
+
+### Push
+
+When asked to push:
+
+1. `git status` - confirm clean or acceptable state
+2. `git log --oneline @{u}..HEAD` - show what will be pushed (if tracking branch exists)
+3. Confirm target remote and branch
+4. `git push` (never `--force` unless T3 preflight completed and confirmed)
+5. Report: commits pushed, remote URL
+
+### Pull Request
+
+When asked to create a PR:
+
+1. `git log --oneline main..HEAD` - commits to include
+2. `git diff --stat main..HEAD` - files changed
+3. Compose PR title (short, under 70 chars) and body:
+   - Summary bullets from commit messages
+   - Test plan if identifiable
+4. `gh pr create --title "..." --body "$(cat <<'EOF' ... EOF)"`
+5. Report: PR number, URL
+
+### Branch Management
+
+When asked to create, switch, or manage branches:
+
+1. `git branch -v` - current branches
+2. `git status` - check for uncommitted work
+3. If uncommitted work exists, warn before switching
+4. Execute branch operation
+5. Report new state
+
+### Release Workflow
+
+When asked to create a release or tag:
+
+1. `git log --oneline $(git describe --tags --abbrev=0 2>/dev/null)..HEAD` - changes since last tag
+2. Determine version bump (from orchestrator context or commit analysis)
+3. Create tag: `git tag -a v{version} -m "Release v{version}"`
+4. If requested, push tag: `git push origin v{version}`
+5. If requested, create GitHub release: `gh release create v{version} --generate-notes`
+6. Report: version, changelog summary
+
+### Changelog Generation
+
+When asked to generate a changelog:
+
+1. Identify version range (last tag to HEAD, or specified range)
+2. `git log --pretty=format:"%s (%h)" <range>` - commit subjects
+3. Categorise by Conventional Commits type (feat, fix, docs, etc.)
+4. Format as markdown changelog section
+5. Report or write to CHANGELOG.md as instructed
+
+## Git Bash Compatibility (Windows)
+
+Always use Unix shell syntax - this runs in Git Bash on Windows:
+
+- Use `2>/dev/null` not `2>nul`
+- Use `wc -l` not `find /c`
+- Use forward slashes in paths
+- Use `$(...)` for command substitution
+
+## What You Do NOT Do
+
+- **Never modify git config** (user.name, user.email, etc.)
+- **Never skip hooks** (no `--no-verify`)
+- **Never execute T3 operations without preflight**
+- **Never push to main/master with --force** (warn even if asked)
+- **Never commit files that look like secrets** (.env, credentials.json, *.pem, *.key)
+- **Never spawn subagents** (you are the subagent)
+
+## Output Format
+
+Always report results in a structured format the orchestrator can relay:
+
+```
+## Result: [Operation]
+
+**Status:** success | failed | needs-confirmation
+**Branch:** [current branch]
+**Details:** [what happened]
+**Next:** [suggested follow-up, if any]
+```
+
+For failures, include the error output and a suggested fix.

+ 1 - 1
docs/RESERVED-COMMANDS.md

@@ -50,7 +50,7 @@ Current claude-mods skills/commands (verified no conflicts):
 - atomise, canvas, explain, introspect, save, setperms, spawn, sync
 
 **Skills:**
-- review, testgen, code-stats, doc-scanner, file-search, find-replace, git-workflow, tool-discovery, task-runner, python-env, structural-search, data-processing, markitdown, etc.
+- review, testgen, code-stats, doc-scanner, file-search, find-replace, git-ops, tool-discovery, task-runner, python-env, structural-search, data-processing, markitdown, etc.
 
 ## Before Adding New Skills
 

+ 1 - 1
rules/naming-conventions.md

@@ -52,7 +52,7 @@ All skills follow the official Anthropic pattern with bundled resources:
 | Operational expertise | `postgres-ops/` | Comprehensive domain knowledge (preferred) |
 | Domain-specific | `python-async-ops/` | Domain + "-ops" |
 | Tool knowledge | `sqlite-ops/` | Tool + "-ops" |
-| Workflow | `git-workflow/` | Activity-focused |
+| Workflow | `git-ops/` | Activity-focused |
 | Framework | `tailwind-ops/` | Framework + "-ops" |
 
 **Naming guidance:** Use `-ops` for all skills providing domain knowledge. The `-ops` suffix signals comprehensive operational expertise - design, implementation, and operations.

+ 1 - 1
skills/ci-cd-ops/SKILL.md

@@ -2,7 +2,7 @@
 name: ci-cd-ops
 description: "CI/CD pipeline patterns with GitHub Actions, release automation, and testing strategies. Use for: github actions, workflow, CI, CD, pipeline, deploy, release, semantic release, changesets, goreleaser, matrix, cache, secrets, environment, artifact, reusable workflow, composite action."
 allowed-tools: "Read Write Bash"
-related-skills: [git-workflow, docker-ops, testing-ops]
+related-skills: [git-ops, docker-ops, testing-ops]
 ---
 
 # CI/CD Operations

+ 1 - 1
skills/debug-ops/SKILL.md

@@ -274,4 +274,4 @@ jq -r 'select(.level == "error") | .error_type' app.log | sort | uniq -c | sort
 - **monitoring-ops** -- Production observability, alerting, dashboards
 - **code-stats** -- Measure code complexity and identify bug-prone areas
 - **container-orchestration** -- Docker and Kubernetes debugging context
-- **git-workflow** -- Git bisect workflow and history investigation
+- **git-ops** -- Git bisect workflow and history investigation

+ 351 - 0
skills/git-ops/SKILL.md

@@ -0,0 +1,351 @@
+---
+name: git-ops
+description: "Git operations orchestrator - commits, PRs, branch management, releases, changelog. Routes lightweight reads inline, dispatches heavy work to background Sonnet agent. Triggers on: commit, push, pull request, create PR, git status, git diff, rebase, stash, branch, merge, release, tag, changelog, semver, cherry-pick, bisect, worktree."
+allowed-tools: "Read Bash Glob Grep Agent TaskCreate TaskUpdate"
+related-skills: [review, ci-cd-ops]
+---
+
+# Git Ops
+
+Intelligent git operations orchestrator. Routes read-only queries inline for speed, dispatches write operations to a background Sonnet agent (`git-agent`) to free the main session.
+
+## Architecture
+
+```
+User intent (commit, PR, rebase, status, etc.)
+    |
+    +---> Tier 1: Read-only (status, log, diff, blame)
+    |       |
+    |       +---> Execute INLINE via Bash (fast, no subagent)
+    |
+    +---> Tier 2: Safe writes (commit, push, tag, PR, stash)
+    |       |
+    |       +---> Gather context from conversation
+    |       +---> Dispatch to git-agent (background, Sonnet)
+    |       |       +---> Fallback: general-purpose with inlined protocol
+    |       +---> Agent executes and reports back
+    |
+    +---> Tier 3: Destructive (rebase, reset, force-push, branch -D)
+            |
+            +---> Dispatch to git-agent (background, Sonnet)
+            |       +---> Fallback: general-purpose with inlined protocol
+            +---> Agent produces PREFLIGHT REPORT (does NOT execute)
+            +---> Orchestrator relays preflight to user
+            +---> On confirmation: re-dispatch with execute authority
+```
+
+## Safety Tiers
+
+### Tier 1: Read-Only - Run Inline
+
+No subagent needed. Execute directly via Bash for instant results.
+
+| Operation | Command |
+|-----------|---------|
+| Status | `git status --short` |
+| Log | `git log --oneline -20` |
+| Diff (unstaged) | `git diff --stat` |
+| Diff (staged) | `git diff --cached --stat` |
+| Diff (full) | `git diff [file]` or `git diff --cached [file]` |
+| Branch list | `git branch -v` |
+| Remote branches | `git branch -rv` |
+| Stash list | `git stash list` |
+| Blame | `git blame [file]` |
+| Show commit | `git show [hash] --stat` |
+| Reflog | `git reflog --oneline -20` |
+| Tags | `git tag --list --sort=-v:refname` |
+| PR list | `gh pr list` |
+| PR status | `gh pr view [N]` |
+| Issue list | `gh issue list` |
+| CI checks | `gh pr checks [N]` |
+| Run status | `gh run list --limit 5` |
+
+For T1 operations, format results cleanly and present directly. Use `delta` for diffs when available.
+
+### Tier 2: Safe Writes - Dispatch to Agent
+
+Gather relevant context, then dispatch to `git-agent` (background, Sonnet).
+
+**Context gathering before dispatch:**
+
+| Operation | Context to Gather |
+|-----------|-------------------|
+| **Commit** | What the user has been working on (from conversation), staged files, recent commit style |
+| **Push** | Current branch, tracking info, commits ahead of remote |
+| **PR create** | All commits on branch vs main, conversation context for description |
+| **Tag/release** | Commits since last tag, version pattern in use |
+| **Stash** | Current changes, user's stash message if provided |
+| **Cherry-pick** | Target commit details, current branch |
+| **Branch create** | Base branch, naming convention from recent branches |
+| **gh issue create** | User description, labels if mentioned |
+
+**Dispatch template:**
+
+```
+You are the git-agent handling a Tier 2 (safe write) operation.
+
+## Context
+- Current branch: {branch}
+- Repository: {repo info}
+- User intent: {what the user asked for}
+- Conversation context: {relevant summary of what was being worked on}
+
+## Operation
+{specific operation details}
+
+## Project Conventions
+{commit style, branch naming, PR template if detected}
+
+Execute the operation following your T2 protocol (verify state, execute, confirm, report).
+```
+
+### Tier 3: Destructive - Preflight Required
+
+Dispatch to `git-agent` with explicit instruction to produce a preflight report ONLY.
+
+**Dispatch template (preflight):**
+
+```
+You are the git-agent handling a Tier 3 (destructive) operation.
+
+## Context
+- Current branch: {branch}
+- Repository: {repo info}
+- User intent: {what the user asked for}
+
+## Operation
+{specific operation details}
+
+IMPORTANT: Do NOT execute this operation. Produce a T3 Preflight Report only.
+Show exactly what will happen, what the risks are, and how to recover.
+```
+
+**After user confirms:** Re-dispatch with execute authority:
+
+```
+User has confirmed the Tier 3 operation after reviewing the preflight.
+
+## Approved Operation
+{exact operation from preflight}
+
+## Confirmation
+Proceed with execution. Follow T3 execution protocol:
+1. Create a safety bookmark: note the current HEAD hash
+2. Execute the operation
+3. Verify the result
+4. Report with the safety bookmark for recovery
+```
+
+## Dispatch Mechanics
+
+### Background Agent (Default for T2/T3)
+
+```python
+# Dispatch to git-agent, runs in background, Sonnet model
+Agent(
+    subagent_type="git-agent",
+    model="sonnet",
+    run_in_background=True,  # Frees main session
+    prompt="..."             # From dispatch templates above
+)
+```
+
+The main session continues working while the agent handles git operations. Results arrive asynchronously.
+
+### Foreground Agent (When Result Needed Immediately)
+
+For operations where the user is waiting on the result (e.g., "commit this then let's move on"):
+
+```python
+Agent(
+    subagent_type="git-agent",
+    model="sonnet",
+    run_in_background=False,  # Wait for result
+    prompt="..."
+)
+```
+
+### Worktree Isolation (Only When Requested)
+
+When the user explicitly asks for worktree isolation (e.g., "do this in a separate worktree", "prepare a branch without touching my working tree"):
+
+```python
+Agent(
+    subagent_type="git-agent",
+    model="sonnet",
+    isolation="worktree",     # Isolated repo copy
+    run_in_background=True,
+    prompt="..."
+)
+```
+
+## Fallback: When git-agent Is Unavailable
+
+If `git-agent` is not registered as a subagent type (e.g., plugin not installed, agent files missing), fall back to `general-purpose` with the git-agent identity inlined in the prompt.
+
+**Detection:** If dispatching to `git-agent` fails or the subagent type is not listed in available agents, switch to fallback mode automatically.
+
+**Fallback dispatch template:**
+
+```python
+Agent(
+    subagent_type="general-purpose",  # Fallback
+    model="sonnet",
+    run_in_background=True,
+    prompt="""You are acting as a git operations agent. You are precise, safety-conscious,
+and follow the three-tier safety system:
+- T1 (read-only): execute freely
+- T2 (safe writes): execute on instruction, verify before and after
+- T3 (destructive): preflight report only unless explicitly told to execute
+
+{original dispatch prompt here}
+"""
+)
+```
+
+**Key differences from primary dispatch:**
+- Uses `general-purpose` instead of `git-agent` subagent type
+- Inlines the safety tier protocol directly in the prompt (the agent won't have git-agent's system prompt)
+- Everything else stays the same - context gathering, templates, foreground/background choice
+
+**When to use each:**
+
+| Condition | Dispatch Method |
+|-----------|----------------|
+| `git-agent` available | Primary: `subagent_type="git-agent"` |
+| `git-agent` unavailable | Fallback: `subagent_type="general-purpose"` with inlined protocol |
+| No agent dispatch possible | Last resort: execute T2 operations inline (main context) |
+
+The last-resort inline path should only be used for simple T2 operations (single commit, simple push). Complex workflows (PR creation, release, changelog) should always use an agent.
+
+## Extended Operations
+
+### Release Workflow
+
+When user asks to "create a release", "bump version", or "tag a release":
+
+1. **Inline (T1):** Check current version and commits since last tag
+   ```bash
+   git describe --tags --abbrev=0 2>/dev/null
+   git log --oneline $(git describe --tags --abbrev=0 2>/dev/null)..HEAD
+   ```
+
+2. **Determine version bump:**
+   - `feat:` commits -> minor bump
+   - `fix:` commits -> patch bump
+   - `BREAKING CHANGE:` or `!:` -> major bump
+   - Or use version specified by user
+
+3. **Dispatch to git-agent (T2):** Tag, push tag, create GitHub release with generated notes
+
+### Changelog Generation
+
+When user asks to "generate changelog" or "update CHANGELOG.md":
+
+1. **Inline (T1):** Gather commit history for the range
+2. **Dispatch to git-agent (T2):** Categorise commits, format as Keep a Changelog, write file
+
+### PR Workflow (Full Cycle)
+
+When user says "create a PR" or "open a PR":
+
+1. **Inline (T1):** Check branch state, diff against main
+2. **Gather context:** What was the user working on? What does the conversation tell us about the goal?
+3. **Dispatch to git-agent (T2):** Create PR with contextual title and body
+4. **Report:** PR number, URL, summary
+
+### Branch Cleanup
+
+When user asks to "clean up branches" or "delete merged branches":
+
+1. **Inline (T1):** List merged branches
+   ```bash
+   git branch --merged main | grep -v "main\|master\|\*"
+   ```
+2. **Show list to user** - this is a T3 preflight (deletion)
+3. **On confirmation:** Dispatch to git-agent to delete them
+
+### Semantic Versioning Analysis
+
+When user asks "what should the next version be":
+
+1. **Inline (T1):** Analyse commits since last tag
+2. Categorise by Conventional Commits
+3. Report recommended bump with reasoning
+
+### Conflict Resolution Support
+
+When user encounters merge conflicts:
+
+1. **Inline (T1):** `git status` to show conflicted files
+2. **Inline (T1):** Read conflict markers in each file
+3. **Present options:** ours, theirs, manual resolution
+4. **After resolution:** Dispatch to git-agent (T2) for staging and continue
+
+## Decision Logic
+
+When a git-related request arrives, follow this flow:
+
+```
+1. Classify the operation tier (T1/T2/T3)
+
+2. If T1:
+   - Execute inline via Bash
+   - Format and present results
+   - DONE
+
+3. If T2:
+   - Gather context (conversation, git state, conventions)
+   - Decide foreground vs background:
+     * User waiting on result? -> foreground
+     * User continuing other work? -> background
+   - Dispatch to git-agent with context
+   - Relay result when received
+
+4. If T3:
+   - Gather context
+   - Dispatch to git-agent for PREFLIGHT ONLY
+   - Present preflight report to user
+   - Wait for explicit confirmation
+   - Re-dispatch with execute authority
+   - Relay result
+```
+
+## Quick Reference
+
+| Task | Tier | Inline/Agent |
+|------|------|-------------|
+| Check status | T1 | Inline |
+| View diff | T1 | Inline |
+| View log | T1 | Inline |
+| List PRs | T1 | Inline |
+| Commit | T2 | Agent |
+| Push | T2 | Agent |
+| Create PR | T2 | Agent |
+| Create tag | T2 | Agent |
+| Create release | T2 | Agent |
+| Stash push/pop | T2 | Agent |
+| Cherry-pick | T2 | Agent |
+| Create branch | T2 | Agent |
+| Rebase | T3 | Agent (preflight) |
+| Force push | T3 | Agent (preflight) |
+| Reset --hard | T3 | Agent (preflight) |
+| Delete branch | T3 | Agent (preflight) |
+| Discard changes | T3 | Agent (preflight) |
+| Merge to main | T3 | Agent (preflight) |
+
+## Tools
+
+| Tool | Purpose |
+|------|---------|
+| `git` | All git operations |
+| `gh` | GitHub CLI - PRs, issues, releases, actions |
+| `delta` | Syntax-highlighted diffs (if available) |
+| `lazygit` | Interactive TUI (suggest to user, not for agent) |
+
+## Additional Resources
+
+For detailed patterns, load:
+- `./references/rebase-patterns.md` - Interactive rebase workflows and safety
+- `./references/stash-patterns.md` - Stash operations and workflows
+- `./references/advanced-git.md` - Bisect, cherry-pick, worktrees, reflog, conflicts

skills/git-workflow/assets/.gitkeep → skills/git-ops/assets/.gitkeep


skills/git-workflow/references/advanced-git.md → skills/git-ops/references/advanced-git.md


skills/git-workflow/references/rebase-patterns.md → skills/git-ops/references/rebase-patterns.md


skills/git-workflow/references/stash-patterns.md → skills/git-ops/references/stash-patterns.md


skills/git-workflow/scripts/.gitkeep → skills/git-ops/scripts/.gitkeep


+ 0 - 106
skills/git-workflow/SKILL.md

@@ -1,106 +0,0 @@
----
-name: git-workflow
-description: "Enhanced git operations using lazygit, gh (GitHub CLI), and delta. Triggers on: stage changes, create PR, review PR, check issues, git diff, commit interactively, GitHub operations, rebase, stash, bisect."
-compatibility: "Requires git, gh (GitHub CLI), lazygit, and delta. Network access needed for GitHub operations."
-allowed-tools: "Bash"
----
-
-# Git Workflow
-
-Streamline git operations with visual tools and GitHub CLI integration.
-
-## Tools
-
-| Tool | Command | Use For |
-|------|---------|---------|
-| lazygit | `lazygit` | Interactive git TUI |
-| gh | `gh pr create` | GitHub CLI operations |
-| delta | `git diff \| delta` | Beautiful diff viewing |
-
-## lazygit Essentials
-
-```bash
-# Open interactive TUI
-lazygit
-
-# Key bindings:
-# Space - stage/unstage file
-# c     - commit
-# p     - push
-# P     - pull
-# b     - branch operations
-# r     - rebase menu
-# s     - stash menu
-# ?     - help
-```
-
-## GitHub CLI (gh) Essentials
-
-```bash
-# Pull Requests
-gh pr create --title "Feature: Add X" --body "Description"
-gh pr create --web           # Open in browser
-gh pr list                   # List open PRs
-gh pr view 123               # View PR details
-gh pr checkout 123           # Check out PR locally
-gh pr merge 123 --squash     # Squash and merge
-
-# Issues
-gh issue create --title "Bug: X"
-gh issue list --label bug
-
-# Repository
-gh repo view --web           # Open in browser
-
-# Actions
-gh workflow run deploy.yml
-gh run list --workflow=ci.yml
-```
-
-## Delta (Beautiful Diffs)
-
-```bash
-# View diff with syntax highlighting
-git diff | delta
-
-# Side-by-side view
-git diff | delta --side-by-side
-
-# Configure as default pager
-git config --global core.pager delta
-```
-
-## Quick Reference
-
-| Task | Command |
-|------|---------|
-| Interactive git | `lazygit` |
-| Create PR | `gh pr create` |
-| Merge PR | `gh pr merge --squash` |
-| Beautiful diff | `git diff \| delta` |
-| Interactive rebase | `git rebase -i HEAD~N` |
-| Stash changes | `git stash push -m "msg"` |
-| Apply stash | `git stash pop` |
-| Find bug commit | `git bisect start` |
-| Cherry-pick | `git cherry-pick <hash>` |
-| Parallel worktree | `git worktree add <path> <branch>` |
-| Recover commits | `git reflog` |
-
-## When to Use
-
-- Interactive staging of changes
-- Creating pull requests from terminal
-- Reviewing PRs and issues
-- Visual diff viewing
-- Cleaning up commit history (rebase)
-- Temporary work saving (stash)
-- Bug hunting (bisect)
-- Parallel feature work (worktrees)
-- Recovering lost work (reflog)
-
-## Additional Resources
-
-For detailed patterns, load:
-- `./references/rebase-patterns.md` - Interactive rebase workflows
-- `./references/stash-patterns.md` - Stash operations and workflows
-- `./references/advanced-git.md` - Bisect, cherry-pick, worktrees, reflog, conflicts

+ 2 - 2
skills/migrate-ops/SKILL.md

@@ -2,7 +2,7 @@
 name: migrate-ops
 description: "Framework and language migration patterns - version upgrades, breaking changes, dependency audit, safe rollback. Use for: migrate, migration, upgrade, version bump, breaking changes, deprecation, dependency audit, npm audit, pip-audit, codemod, jscodeshift, rector, rollback, semver, changelog, framework upgrade, language upgrade, React 19, Vue 3, Next.js App Router, Laravel 11, Angular, Python 3.12, Node 22, TypeScript 5, Go 1.22, Rust 2024, PHP 8.4."
 allowed-tools: "Read Edit Write Bash Glob Grep Agent"
-related-skills: [testing-ops, debug-ops, git-workflow, refactor-ops]
+related-skills: [testing-ops, debug-ops, git-ops, refactor-ops]
 ---
 
 # Migrate Operations
@@ -271,7 +271,7 @@ Migration failed or caused issues — how to roll back?
 |-------|----------------|
 | `testing-ops` | Ensuring test coverage before migration, writing regression tests after |
 | `debug-ops` | Diagnosing failures introduced by migration, bisecting breaking commits |
-| `git-workflow` | Branch strategy for migration, git bisect to find breaking change |
+| `git-ops` | Branch strategy for migration, git bisect to find breaking change |
 | `refactor-ops` | Code transformations that often accompany version upgrades |
 | `ci-cd-ops` | Updating CI pipelines to test against new versions, matrix builds |
 | `container-orchestration` | Updating base images, Dockerfile changes for new runtime versions |

+ 1 - 1
skills/refactor-ops/SKILL.md

@@ -291,4 +291,4 @@ Refactoring Untested Code
 | `debug-ops` | When refactoring exposes hidden bugs or introduces regressions |
 | `code-stats` | Measure complexity before and after refactoring to quantify improvement |
 | `migrate-ops` | Large-scale migrations that require systematic refactoring |
-| `git-workflow` | Branch strategy for refactoring PRs, stacked PRs, bisect to find regressions |
+| `git-ops` | Branch strategy for refactoring PRs, stacked PRs, bisect to find regressions |

+ 1 - 1
skills/tool-discovery/SKILL.md

@@ -31,7 +31,7 @@ Is this a reference/lookup task?
 | **code-stats** | tokei, difft, line counts |
 | **data-processing** | jq, yq, json, yaml |
 | **structural-search** | ast-grep, sg, ast pattern |
-| **git-workflow** | lazygit, gh, delta, rebase |
+| **git-ops** | git, gh, lazygit, delta, commit, PR, release, rebase |
 | **python-env** | uv, venv, pyproject |
 | **go-ops** | golang, go, goroutine, channel, context, errgroup, go test |
 | **rust-ops** | rust, cargo, ownership, tokio, serde, trait, Result, Option |

+ 12 - 8
skills/tool-discovery/references/skills-catalog.md

@@ -426,16 +426,20 @@ Modern command-line tools for development workflows.
 
 Project and development workflow automation.
 
-### git-workflow
+### git-ops
 
-**Triggers:** lazygit, gh, delta, pr, rebase, stash, bisect
+**Triggers:** commit, push, pull request, create PR, git status, git diff, rebase, stash, branch, merge, release, tag, changelog, semver, cherry-pick, bisect, worktree, lazygit, gh, delta
 
 **Use For:**
+- Commit, push, and branch management (dispatched to background Sonnet agent)
+- PR creation with contextual titles and descriptions
+- Release workflows - tagging, GitHub releases, changelog generation
+- Semantic versioning analysis from Conventional Commits
 - Interactive git operations (lazygit)
 - GitHub CLI (gh) commands
-- Syntax-highlighted diffs (delta)
-- Rebase and stash patterns
-- Bug hunting with bisect
+- Safety-tiered operations (read-only inline, safe writes dispatched, destructive with preflight)
+
+**Agent:** git-agent (model: sonnet, background)
 
 **References:** rebase-patterns.md, stash-patterns.md, advanced-git.md
 
@@ -510,7 +514,7 @@ Project and development workflow automation.
 | Python | python-env, structural-search |
 | API design | api-design-ops, rest-ops |
 | Docker/containers | docker-ops, container-orchestration |
-| CI/CD | ci-cd-ops, git-workflow |
+| CI/CD | ci-cd-ops, git-ops |
 | CSS/Tailwind | tailwind-ops |
 | Nginx/web server | nginx-ops |
 | Auth/security | auth-ops, security-ops |
@@ -526,7 +530,7 @@ Project and development workflow automation.
 | Count lines of code | code-stats |
 | Compare code changes | code-stats |
 | Process JSON/YAML | data-processing |
-| Git operations | git-workflow |
+| Git operations | git-ops |
 | Set up Python project | python-env |
 | Run project tasks | task-runner |
 | Find project docs | doc-scanner |
@@ -547,7 +551,7 @@ Project and development workflow automation.
 **Medium Tasks (1-5 min):**
 - find-replace: Batch replacements
 - data-processing: JSON transformations
-- git-workflow: Rebase operations
+- git-ops: Rebase, PR creation, release workflows
 - python-env: Project setup
 
 **Complex Workflows (5+ min):**