Expand description
Garbage collection for the shared cache.
The key idea: every artifact in the cache belongs to a build “unit”
identified by a name-hash key (Cargo appends a metadata hash to
filenames). Deleting a whole unit keeps Cargo’s bookkeeping consistent;
and if anything still needed got deleted, Cargo simply rebuilds it —
pruning is safe by design.
Structs§
- Group
- One build unit: all files in the cache sharing a
name-hashkey. - Prune
Report
Functions§
- artifact_
key - Classify a file inside the cache into its build unit.
- prune
- The garbage collector.
- scan
- Walk
rootand group every file into units.