pub fn cache_dir() -> PathBufExpand description
Returns the source-data cache directory, resolved at call time as the first match in this chain:
$UTZ_CACHE_DIR(the μTZ workspace pins this to itscache/via.cargo/config.toml, so in-repo builds share one cache).$XDG_CACHE_HOME/utz_build.%LOCALAPPDATA%\utz_build(Windows) or$HOME/.cache/utz_build.$OUT_DIR/utz_build-cache(the build-script last resort), and otherwise./utz_build-cacherelative to the current directory.
Config::cache_dir() overrides the
chain per build. Everything inside is a re-fetchable download (TZBB
zips keyed per release, the ~460 MB GHS-POP raster and its decoded
sidecar), so the directory is safe to delete. Build scripts that
depend on the chain should emit
cargo:rerun-if-env-changed=UTZ_CACHE_DIR.