From go-workflow
Interactively selects and safely removes a specific git worktree for issues, checking if linked issue is closed, branch merged into default, and no uncommitted changes before removal, with optional branch deletion.
npx claudepluginhub gopherguides/gopher-ai --plugin go-workflowThis skill uses the workspace's default tool permissions.
Interactively select and safely remove a single git worktree.
Generates design tokens/docs from CSS/Tailwind/styled-components codebases, audits visual consistency across 10 dimensions, detects AI slop in UI.
Records polished WebM UI demo videos of web apps using Playwright with cursor overlay, natural pacing, and three-phase scripting. Activates for demo, walkthrough, screen recording, or tutorial requests.
Delivers idiomatic Kotlin patterns for null safety, immutability, sealed classes, coroutines, Flows, extensions, DSL builders, and Gradle DSL. Use when writing, reviewing, refactoring, or designing Kotlin code.
Interactively select and safely remove a single git worktree.
$remove-worktree
git worktree list
Filter for issue worktrees (matching *-issue-* pattern). If none found, inform the user and stop.
If multiple worktrees exist, list them and ask the user which one to remove.
For the selected worktree, check:
Issue status: Is the linked issue closed?
ISSUE_NUM=$(echo "$WORKTREE_PATH" | grep -oE 'issue-([0-9]+)' | grep -oE '[0-9]+')
gh issue view "$ISSUE_NUM" --json state --jq '.state'
Merge status: Is the branch merged into the default branch?
DEFAULT_BRANCH=$(git remote show origin | grep 'HEAD branch' | sed 's/.*: //')
BRANCH_NAME=$(cd "$WORKTREE_PATH" && git branch --show-current)
git branch --merged "$DEFAULT_BRANCH" | grep -q "$BRANCH_NAME"
Uncommitted changes: Are there any pending changes?
cd "$WORKTREE_PATH" && git status --porcelain
Safe removal (issue closed + branch merged + no uncommitted changes):
Ask: "Remove worktree at $WORKTREE_PATH? (issue closed, branch merged)"
git worktree remove "$WORKTREE_PATH"
Unsafe removal (issue open, branch unmerged, or uncommitted changes):
Warn the user about the risks and ask for explicit confirmation:
git worktree remove --force "$WORKTREE_PATH"
Ask: "Also delete the branch $BRANCH_NAME?"
git branch -D "$BRANCH_NAME" 2>/dev/null || true
git push origin --delete "$BRANCH_NAME" 2>/dev/null || true