pub fn prune_wasm_build_cache(
target_dir: &Path,
policy: WasmBuildCachePrunePolicy,
) -> Result<WasmBuildCachePruneReport, WasmBuildError>Expand description
Prune fingerprint-specific Cargo target directories under target_dir.
Pruning uses the same exclusive process lock as builds. Entries older than the configured age are removed first, then least-recently-used entries are removed until the configured logical byte limit is met. Only direct child directories with SHA-256 fingerprint names are eligible; caller-facing artifacts and unrelated target contents are never removed.