Current state
get_brew_outdated_formula_list in tools/homebrew/utils.bash references NPM_OUTDATED_LIST_CACHE_FILE — a variable defined in tools/node/utils.bash — on both lines 96 (existence check) and 102 (stat age check). The function is intended to manage a brew-specific cache, but it reads and checks the age of the npm cache file instead. This means the function either finds the npm cache when it expects to find the brew cache, or misses the brew cache entirely — making the cache-age logic silently wrong.
Ideal state
get_brew_outdated_formula_list references BREW_OUTDATED_LIST_CACHE_FILE on both lines 96 and 102.
- The function behaves identically to the parallel npm utility, reading and checking the correct brew-specific cache file.
- No reference to
NPM_OUTDATED_LIST_CACHE_FILE exists within tools/homebrew/utils.bash.
Starting points
tools/homebrew/utils.bash lines 88–110 — the full get_brew_outdated_formula_list function
tools/node/utils.bash — the parallel npm pattern this function should mirror
QA plan
- Run
grep -n "NPM_OUTDATED_LIST_CACHE_FILE" tools/homebrew/utils.bash — expect no output.
- Open
tools/homebrew/utils.bash and confirm both the existence check and the stat call use BREW_OUTDATED_LIST_CACHE_FILE.
- Source the file and call
get_brew_outdated_formula_list — expect it to check and populate a brew-specific cache file, not the npm one.
Done when
get_brew_outdated_formula_list references BREW_OUTDATED_LIST_CACHE_FILE exclusively and contains no reference to NPM_OUTDATED_LIST_CACHE_FILE.
Current state
get_brew_outdated_formula_listintools/homebrew/utils.bashreferencesNPM_OUTDATED_LIST_CACHE_FILE— a variable defined intools/node/utils.bash— on both lines 96 (existence check) and 102 (statage check). The function is intended to manage a brew-specific cache, but it reads and checks the age of the npm cache file instead. This means the function either finds the npm cache when it expects to find the brew cache, or misses the brew cache entirely — making the cache-age logic silently wrong.Ideal state
get_brew_outdated_formula_listreferencesBREW_OUTDATED_LIST_CACHE_FILEon both lines 96 and 102.NPM_OUTDATED_LIST_CACHE_FILEexists withintools/homebrew/utils.bash.Starting points
tools/homebrew/utils.bashlines 88–110 — the fullget_brew_outdated_formula_listfunctiontools/node/utils.bash— the parallel npm pattern this function should mirrorQA plan
grep -n "NPM_OUTDATED_LIST_CACHE_FILE" tools/homebrew/utils.bash— expect no output.tools/homebrew/utils.bashand confirm both the existence check and thestatcall useBREW_OUTDATED_LIST_CACHE_FILE.get_brew_outdated_formula_list— expect it to check and populate a brew-specific cache file, not the npm one.Done when
get_brew_outdated_formula_listreferencesBREW_OUTDATED_LIST_CACHE_FILEexclusively and contains no reference toNPM_OUTDATED_LIST_CACHE_FILE.