(fix) format item counts with thousands separators across CLI#23
(fix) format item counts with thousands separators across CLI#23Aydeing wants to merge 2 commits into
Conversation
Add :, format spec to all bare item(s) counts in undo_cmd, apps leftovers, and junk clean output for consistency with junk.py's existing formatted counts. Fixes #1
|
Thanks for your first pull request to Sifty! A couple of things that help it land quickly: Sifty deletes files, so all deletion must go through |
Vortrix5
left a comment
There was a problem hiding this comment.
Looks good, happy to merge. The :, change is safe (these are all integer counts) and it matches how junk clean and the profile command already format their numbers.
One nit, not a blocker: the title says "across CLI" but this really only covers undo, apps leftovers, and junk clean. There are still bare counts in cleanup, purge and organize that'll drift for large numbers. Either tighten the title or sweep the rest in a follow-up, whatever you prefer.
Thanks for the fix!
Sweep the :, format spec across every remaining user-facing integer count in the CLI so the change is genuinely across-CLI: cleanup, purge, organize, optimize, apps, profile, updates, startup, disk, and the checkup summary in app.py. Display-only: JSON output, size/percent/threshold values are left untouched. Matches the existing formatted counts in junk clean, undo, and apps leftovers. Fixes #1
|
Thanks for the review! Swept the rest so the "across CLI" title holds. Pushed a commit covering every remaining bare integer count:
JSON output, sizes ( |
What does this PR do?
Fixes #1 — Adds thousands separators (
:,format spec) to every user-facing integer count across the CLI, so large counts no longer render as bare digits (e.g.27803→27,803). Matches the formattingjunk cleanand the profile command already use.Covered:
undo,apps(leftovers + list/startup/orphans titles),junk clean,cleanup(duplicates/stale/worktrees),purge,organize,optimize,profile,updates,startup,diskduplicates, and thecheckupsummary.Safety checklist
Sifty deletes files, so every PR keeps these promises:
pytestis green, includingtests/test_safety.py(182/182 passed)os.remove,shutil.rmtree,Path.unlink); everything goes throughsafety.trash()Notes for the reviewer
Display-only change: adds
:,to integer count interpolations across 10 files. No logic, deletion, or core changes. JSON output (output.emit), byte sizes (human_size), percentages, version strings, and day/threshold values are intentionally left unformatted.ruff check .passes clean.