为什么我的 Homebrew bash 完成路径突然丢失了?

Why are my Homebrew bash completion paths suddenly missing?

自从我对 Homebrew 进行了最新更新后,我在尝试设置路径完成时突然收到以下警告,就像我一直所做的那样,使用命令(在我的 bash_profile 中)例如

source $(brew --repository)/etc/bash_completion.d/git-completion.bash

自上次工作以来我所做的唯一一件事是 运行 brew update && echo; brew upgrade --all

如何修复此错误并恢复对我的路径完成的访问。为什么会造成这种情况。


-bash: /usr/local/Homebrew/etc/bash_completion.d/git-completion.bash: No such file or directory
-bash: /usr/local/Homebrew/etc/bash_completion.d/git-prompt.sh: No such file or directory
-bash: /usr/local/Homebrew/bin/eb_completion.bash: No such file or directory
-bash: /usr/local/Homebrew/etc/bash_completion.d/cabal: No such file or directory
-bash: /usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/path.bash.inc: No such file or directory
-bash: /usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/completion.bash.inc: No such file or directory

更新:在最新的 brew update && echo; brew upgrade --all 之后,我现在得到

-bash: /usr/local/Homebrew/etc/bash_completion.d/git-completion.bash: No such file or directory
-bash: /usr/local/Homebrew/etc/bash_completion.d/git-prompt.sh: No such file or directory
-bash: /usr/local/Homebrew/bin/eb_completion.bash: No such file or directory
-bash: /usr/local/Homebrew/etc/bash_completion.d/cabal: No such file or directory

表示 $(brew --repository)(brew --prefix)