安装
npx skillscat add dyoshikawa/rulesync/clean-worktrees 通过 SkillsCat registry 安装。
技能简介
清理由 git-worktree-runner 创建的 git 工作树,移除非默认分支并修剪已删除的远程分支。用于维护整洁的本地 git 环境。
SKILL.md
- Run
git gtr listto list all worktrees. - For each worktree branch that is NOT the default branch (e.g. main), run
git gtr rm --force {branch}to remove it. - Run
git pull --pruneto fetch latest changes and prune deleted remote branches.