dyoshikawa

clean-worktrees

Cleans up git worktrees created by git-worktree-runner by removing non-default branches and pruning deleted remotes. Use this to maintain a tidy local git environment.

dyoshikawa 1,548 167 Updated 3mo ago
GitHub

Install

npx skillscat add dyoshikawa/rulesync/clean-worktrees

Install via the SkillsCat registry.

About this skill

Cleans up git worktrees created by git-worktree-runner by removing non-default branches and pruning deleted remotes. Use this to maintain a tidy local git environment.

SKILL.md
  1. Run git gtr list to list all worktrees.
  2. For each worktree branch that is NOT the default branch (e.g. main), run git gtr rm --force {branch} to remove it.
  3. Run git pull --prune to fetch latest changes and prune deleted remote branches.