cleaner-core
Reusable, high-performance disk scanning, directory tree sizing, and temporary artifact cleaning engine for Rust.
Features
- Blazing Fast Scanning: Highly parallel filesystem traversal using Rayon worker pools.
- Platform-Native Traversal: Optimized batched syscalls (such as
getattrlistbulkon macOS). - Single-Pass Sizing & Indexing: Calculates recursive directory sizes in-place with minimal heap allocations.
- Configurable Pattern Matching: Fast precompiled matching for development artifacts (
node_modules,target,__pycache__, etc.). - System Protection: Built-in protection boundaries that prevent destructive actions on critical system folders and toolchains.
- Cross-Platform: Full support for Linux, macOS, Windows, and FreeBSD.
Usage
Add this to your Cargo.toml:
[]
= "0.1"
Basic Example
use Config;
use PatternMatcher;
use ;
use Path;
use AtomicBool;
use Arc;
License
Dual-licensed under MIT or Apache 2.0.