feat(cli): uninstall finds every copy — PATH/standard scan + Windows live-drive coverage#499
Merged
Merged
Conversation
…live-drive coverage Make `uffs --uninstall` discover and remove UFFS wherever it actually lives, across both platforms, while never touching a shared bin dir it does not own. - PATH + standard-dir scan (which-style, stat-only, no walk): finds copies that are neither running nor the invoking exe, folded into the main plan. Reuses the real channel/scope classifier (WinGet delegated, root-owned dirs flagged for sudo). - Retired/optional binary names (uffs-daemon, uffs-mcp, uffs_tui, …) swept wherever they sit in a root. - PATH safety gate: only a dedicated uffs*-only directory is offered for PATH removal; a shared ~/bin / ~/.local/bin is left alone (we never added it). - Windows deep sweep: ask UFFS itself for stray copies on the live drives, version them, and remove under a SEPARATE confirmation (a copy placed by the user might be among them). - Windows drive-coverage: before the sweep, check which NTFS drives the daemon indexes and offer to start it / index the missing ones for a complete sweep. Runs under --dry-run too (start/index are non-destructive); only deletions are withheld. Off Windows there is no daemon sweep (UFFS indexes offline captures there, not the live filesystem), so the deep-sweep subsystem is #[cfg(windows)]. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Makes
uffs --uninstalldiscover and remove UFFS wherever it actually lives, across both platforms, while never touching a shared bin dir it does not own.Cross-platform
which-style, stat-only, no filesystem walk): finds copies that are neither running nor the invoking exe (e.g. a seconduffsonPATH), folded into the main plan. Reuses the real channel/scope classifier, so a WinGet copy is still delegated and a root-owned/usr/local/bincopy is still flagged forsudo.uffs-daemon,uffs-mcp,uffs_tui, …) swept wherever they sit in a root.uffs*-only directory is offered for PATH removal; a shared~/bin/~/.local/binis left alone (we never added it).Windows-only (UFFS indexes the live drives there)
--dry-runtoo — start/index are non-destructive; only deletions are withheld.Off Windows there is no daemon sweep (UFFS indexes offline captures there, not the live filesystem), so the deep-sweep subsystem is
#[cfg(windows)].Testing
uffs-clitests pass on macOS.cargo xwin clippy --all-targets.🤖 Generated with Claude Code