Skip to content

Group the mass-deletion review by top-level folder (#182) - #192

Merged
gnacho merged 1 commit into
mainfrom
feat/182-delete-review-grouping
Aug 26, 2026
Merged

gnacho merged 1 commit into
mainfrom
feat/182-delete-review-grouping

Conversation

@gnacho

@gnacho gnacho commented Aug 26, 2026

Copy link
Copy Markdown
Owner

Closes #182.

Problem

The delete-guard review dialog lists up to 100 individual missing paths in a flat list. For a large cleanup (removing a vendored SDK, virtualenvs or build caches - thousands of files across a handful of directories) the flat list is overwhelming: the user cannot tell at a glance what is about to be deleted, which is exactly the decision the dialog exists to support.

Change

Group the missing paths by their first path component (top-level directory relative to the folder root) and show one row per group:

  • Group row: folder icon + directory name + file count.
  • Groups with few files (<= 5) are listed as individual file rows instead.
  • Large groups use an expander so the individual paths stay inspectable.
  • Exact total kept in the dialog body; groups ordered by size (desc).

Files

  • src/core/delete_guard.rs (+156): group/aggregate the missing paths.
  • src/ui/main_window.rs: render the grouped rows with expanders.
  • po/es.po + src/util/translations/es.rs: new i18n entries.

Gate: clippy clean, fmt applied, tests green.

…182)

The review dialog listed up to 100 individual missing paths in a flat list.
For a large cleanup (removed SDK, virtualenv, build caches) that wall of
paths is unreadable in a small window. Missing paths are now grouped by
their first path component: one expandable row per directory with its file
count (folder icon, count subtitle), expanded children capped, and small
groups plus loose files listed individually. Rows are sorted by group size.
The grouping lives in a pure, unit-tested function.
@gnacho
gnacho merged commit 3a22b8b into main Aug 26, 2026
2 checks passed
@gnacho
gnacho deleted the feat/182-delete-review-grouping branch August 26, 2026 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Group the mass-deletion review by top-level folder instead of a flat path list

1 participant