Command Palette

Search for a command to run...

Назад к скиллам
скилл № 55637

worktree-merge

Merge a worktree branch into main, remove the worktree, and delete the branch. Use when done with a worktree and ready to integrate or discard the work.

БесплатноБез исполняемых скриптов
incubateur-ademeот incubateur-ademe★ 45 звёзд на GitHub

Установить worktree-merge в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Об этом скилле

Worktree Cleanup

Merge a completed worktree branch into main, remove the worktree directory, and delete the branch.

Instructions

Step 1: List active worktrees

Run git worktree list and parse the output to find all worktrees except the main one.

If there are no worktrees to clean up, tell the user and stop.

Step 2: Ask user which worktree to clean up

Use the AskUserQuestion tool to present the list of active worktrees as options. Show the branch name and directory path in each option.

Step 3: Confirm merge strategy

Use AskUserQuestion to ask whether to:

  1. Merge into main — merge the branch into main before cleanup
  2. Remove only — just remove the worktree and branch without merging (for abandoned work)

Step 4: Execute cleanup

If merging:

# 1. Ensure we're on main and up to date
git checkout main

# 2. Merge the branch
git merge --ff-only <branch-name>

# 3. Remove worktree and delete branch
scripts/remove-worktree.sh <branch-name> --delete-branch

If removing without merge:

# Remove worktree and delete branch
scripts/remove-worktree.sh <branch-name> --delete-branch

Step 5: Report result

Show what was done: merged (if applicable), worktree removed, branch deleted.

Arguments

$ARGUMENTS

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

  1. 01Bash

FAQ

Что делает скилл worktree-merge?

Merge a worktree branch into main, remove the worktree, and delete the branch. Use when done with a worktree and ready to integrate or discard the work.

Как установить скилл worktree-merge?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл worktree-merge запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить worktree-merge с