Merge pull request #11027 from bosr/fix/zsh-completion

fix _brew completion default cache path
This commit is contained in:
Rylan Polster 2021-04-05 09:34:41 -04:00 committed by GitHub
commit 1d612fb0f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -44,7 +44,7 @@ __brew_completion_caching_policy() {
(( $#tmp )) || return 0
# otherwise, invalidate if latest tap index file is missing or newer than cache file
tmp=( ${HOMEBREW_REPOSITORY:-/usr/local/Homebrew}/Library/Taps/*/*/.git/index(om[1]N) )
tmp=( $(brew --repository)/Library/Taps/*/*/.git/index(om[1]N) )
[[ -z $tmp || $tmp -nt $1 ]]
}

View File

@ -47,7 +47,7 @@ __brew_completion_caching_policy() {
(( $#tmp )) || return 0
# otherwise, invalidate if latest tap index file is missing or newer than cache file
tmp=( ${HOMEBREW_REPOSITORY:-/usr/local/Homebrew}/Library/Taps/*/*/.git/index(om[1]N) )
tmp=( $(brew --repository)/Library/Taps/*/*/.git/index(om[1]N) )
[[ -z $tmp || $tmp -nt $1 ]]
}