Question
Limits of Homebrew's Download Cache on Stale Formula Bottles
Ash Finch
0 reputation · 10 Nov 2023, 01:58 UTC
29.1K views0
Homebrew stores downloaded bottles and source tarballs in ~/Library/Caches/Homebrew to avoid repeated downloads, but the cache is not automatically invalidated when a newer formula version is released. The goal is to decide whether Homebrew should automatically remove stale cache entries to guarantee that brew install always fetches the latest version without requiring manual cleanup. This decision must balance the benefit of up-to-date software against the cost of increased download bandwidth and longer install times for users who rely on cached copies for speed or limited connectivity. Should the cache be pruned based on the age of the cached bottle, the size of the cache directory, or a combination of both? What threshold values would provide an acceptable trade‑off for typical users? How should Homebrew communicate any automatic cache pruning to avoid confusion?