How tutyamxx/steam-sweep works
Steam Sweep is a Windows Electron utility that discovers Steam libraries and games, scans for removable leftovers, lets users review and select candidates with reclaimable sizes, then revalidates and moves selected items to the Recycle Bin. The renderer presents scanning and cleanup controls; Electron main-process handlers coordinate discovery, worker-based scanning, cleanup, window actions, and updates. README capabilities are retained, including multi-library discovery and automatic updates. Some renderer-to-main IPC wiring is not shown in the excerpts, so that boundary is marked unverified.
Main entry points: main.ts IPC orchestration · Home.tsx Home workflow · scanner.ts Leftover scanner · cleanup.ts Validated cleanup
Components 20
Desktop interface
- Home workflow
src/pages/Home.tsx - Scan controls
src/components/ScanSection.tsx - Candidate selection
src/components/CleanupList.tsx - Window controls
src/components/TitleBar.tsx - Logo display
src/components/SteamSweepLogo.tsx
Electron runtime
- IPC orchestration
electron/main.ts - Renderer bridge
electron/preload.ts - App updates
electron/updater.ts
Steam discovery
- Steam installation lookup
electron/steam/discovery.ts - Library discovery
electron/steam/libraryFolders.ts - Installed game discovery
electron/steam/games.ts - Game manifests
electron/steam/manifests.ts
Scan and cleanup
- Scan worker
electron/cleanup/scanner.worker.ts - Leftover scanner
electron/cleanup/scanner.ts - Detection rules
electron/cleanup/rules.ts - Validated cleanup
electron/cleanup/cleanup.ts
Shared support
- Candidate data contract
types/cleanup.ts
Other components
- Steam Sweep user
- Local game files
- Windows Recycle Bin
Connections 21
- Steam Sweep user → Home workflow: uses
README.md - Home workflow → Scan controls: renders
src/pages/Home.tsx - Home workflow → Candidate selection: renders
src/pages/Home.tsx - Home workflow → Window controls: renders
src/pages/Home.tsx - Home workflow → Logo display: renders
src/pages/Home.tsx - Home workflow → IPC orchestration: requests scan and cleanup
- IPC orchestration → Renderer bridge: exposes renderer bridge
- IPC orchestration → Steam installation lookup: locates Steam
electron/main.ts - IPC orchestration → Library discovery: discovers libraries
electron/main.ts - IPC orchestration → Installed game discovery: finds installed games
electron/main.ts - IPC orchestration → Scan worker: dispatches scans
electron/main.ts - Scan worker → Leftover scanner: runs scan logic
electron/cleanup/scanner.worker.ts - IPC orchestration → Validated cleanup: cleans validated candidates
electron/main.ts - Installed game discovery → Game manifests: reads manifests
electron/steam/games.ts - Leftover scanner → Detection rules: applies detection rules
electron/cleanup/scanner.ts - Leftover scanner → Local game files: inspects files
README.md - Validated cleanup → Local game files: revalidates candidates
- Validated cleanup → Windows Recycle Bin: moves selected items
README.md - IPC orchestration → App updates: sets up updates
electron/main.ts - Home workflow → App updates: shows update status
- Candidate selection → Candidate data contract: displays candidates
src/components/CleanupList.tsx