cleanup-worktreeslisted
Install: claude install-skill ostin-pil/claude-plugins
Sweep leftover worktrees under `worktree_dir` (`.claude/worktrees/` for
Untype) and the branches they reference. Counterpart to `/finalize-worktree`:
finalize handles the happy path (merge + remove one worktree), this handles
the accumulated debris from parallel-agent sessions that were abandoned,
crashed, or whose work already landed via a different path.
## Project configuration
The manifest is this skill's configuration. If
`$(git rev-parse --show-toplevel)/.claude/lifecycle-manifest.md` does not exist, the
project has not adopted the kit: say so, offer to create it, and stop. Never infer
the keys and run anyway. The kit ships the template as
`lifecycle-manifest.template.md`; locate the installed copy with
`find ~/.claude/plugins -path '*lifecycle-kit*' -name lifecycle-manifest.template.md | head -1`.
The marketplace's `ADOPTING.md` carries a repo-inspecting setup prompt.
Read `.claude/lifecycle-manifest.md` first (resolve via
`$(git rev-parse --show-toplevel)/.claude/lifecycle-manifest.md`). Where a
step names a manifest key in `code font` (`worktree_dir`, `worktree_ignore`,
`orphan_branch_globs`, `scratch_paths`), use that key's value. The containment
commands write the ref as `<integration_ref>` and the remote as `<remote>`;
replace each with the manifest value before running. The surrounding prose still
names `origin/main` with Untype's value for readability. The `ahead=0`
containment proof and the `-D`-vs-`-d` seam are the skill's logic, not
configuration.
## Safe