Skip to main content

Module delete_batch

Module delete_batch 

Source
Expand description

Batch deletion orchestration for gw delete.

Multi-target deletion pipeline: resolve-all → plan (busy) → summary → confirm → execute → exit code. Reuses worktree::delete_one for per-target execution.

Structs§

Resolved
Resolved worktree target (path + optional branch).

Enums§

PlanEntry
A single entry in the batch execution plan.

Functions§

confirm_batch
Ask for a single y/N confirmation on the whole batch. Only invoked when planned.ready > 1 (or planned.ready >= 1 combined with skips worth surfacing). Returns true if the user confirmed.
delete_worktrees
Top-level orchestrator for gw delete.
plan_busy
Annotate resolved entries with busy status. Unresolved entries pass through.
print_summary
Print the batch summary. Goes to stdout to match the convention used by gw clean (summary/progress → stdout, errors/prompts → stderr).
resolve_all
Resolve a list of user inputs against the main repository.