How adileo/squirreldisk works
SquirrelDisk is a cross-platform disk-usage explorer and cleanup app. Users start a local, remote, or cloud scan; the scanner builds a live tree that the app presents as a sunburst or treemap, then users collect items and safely delete or back them up. Other documented capabilities include CLI scans, filesystem-change refresh, account management, self-updates, localization, and on-device sponsor selection. Some subsystem links reflect README descriptions because their implementation excerpts were not provided; those links are marked dashed.
Main entry points: app.rs Desktop app · tree.rs Disk tree · remote.rs Remote scanner · local.rs Local scanner
Components 26
Scanning
- Scan dispatch
src/scan/mod.rs - Local scanner
src/scan/local.rs - Platform filesystem access
src/scan/platform.rs - Remote scanner
src/scan/remote.rs - Demo scanner
src/scan/demo.rs - Path tree builder
src/scan/pathtree.rs - Disk tree
src/tree.rs
Explore and manage
- Desktop app
src/ui/app.rs - Sunburst view
src/ui/sunburst.rs - Treemap view
src/ui/treemap.rs - Exploration panels
src/ui/view.rs - UI widgets
src/ui/widgets.rs - Command-line scans
src/cli.rs
Cleanup and integrations
- Cleanup operations
src/delete.rs - Deletion safeguards
src/safety.rs - Cloud account and transfer
src/rclone.rs - Filesystem watcher
src/watch.rs
App services
- Settings
src/settings.rs - Self updater
src/update.rs - Localization
src/i18n.rs - Sponsor selection
src/sponsor/mod.rs
Other components
- User
- CLI user
- Local filesystem
- SSH and cloud sources
- Sponsor catalog service
Connections 35
- User → Desktop app: starts scan
- CLI user → Command-line scans: runs scan
- Command-line scans → Local scanner: scans locally
src/cli.rs - Command-line scans → Disk tree: prints results
src/cli.rs - Desktop app → Scan dispatch: requests scan
src/ui/app.rs - Scan dispatch → Local scanner: dispatches local
src/scan/mod.rs - Scan dispatch → Remote scanner: dispatches remote
src/scan/mod.rs - Scan dispatch → Demo scanner: dispatches demo
src/scan/mod.rs - Local scanner → Platform filesystem access: reads entries
src/scan/local.rs - Local scanner → Disk tree: builds tree
src/scan/local.rs - Remote scanner → Path tree builder: builds paths
src/scan/remote.rs - Remote scanner → Disk tree: builds tree
src/scan/remote.rs - Remote scanner → Cloud account and transfer: uses rclone
src/scan/remote.rs - Demo scanner → Disk tree: builds demo tree
src/scan/demo.rs - Local filesystem → Local scanner: provides entries
- SSH and cloud sources → Remote scanner: provides data
- Desktop app → Disk tree: explores tree
src/ui/app.rs - Desktop app → Sunburst view: renders chart
src/ui/app.rs - Desktop app → Treemap view: renders chart
src/ui/app.rs - Desktop app → Exploration panels: shows details
src/ui/app.rs - Sunburst view → Disk tree: reads tree
src/ui/sunburst.rs - Treemap view → Disk tree: reads tree
src/ui/treemap.rs - Exploration panels → Disk tree: reads tree
src/ui/view.rs - Desktop app → UI widgets: uses controls
src/ui/app.rs - User → Cleanup operations: requests cleanup
- Cleanup operations → Deletion safeguards: checks targets
src/delete.rs - Cleanup operations → Disk tree: resolves items
src/delete.rs - Cleanup operations → Cloud account and transfer: backs up remotely
src/delete.rs - Desktop app → Filesystem watcher: refreshes scans
src/ui/app.rs - Desktop app → Settings: loads preferences
src/ui/app.rs - Desktop app → Self updater: checks updates
src/ui/app.rs - Desktop app → Localization: translates interface
src/ui/app.rs - Desktop app → Sponsor selection: shows banner
src/ui/app.rs - Sponsor selection → Sponsor catalog service: fetches catalog
src/sponsor/mod.rs - User → Cloud account and transfer: manages accounts