安裝brew報告,發現它找不到git,並死於錯誤。啤酒似乎已經被安裝Brew找不到git,儘管git在路徑中(Mac/OSX)
> brew
(打印常用的幫助)
...但brew doctor
不開心(成功):
這是我所得到的,當我運行(當我按照Homebrew主頁的說明首次安裝啤酒時)。
> brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry and just ignore them. Thanks!
Warning: Git could not be found in your PATH.
Homebrew uses Git for several internal functions, and some formulae use Git
checkouts instead of stable tarballs. You may want to install Git:
brew install git
Error: Git is unavailable
Error: Failure while executing: /usr/local/bin/brew tap homebrew/core -q
我的路徑:
> echo $PATH
/usr/local/bin:/opt/local/bin:/opt/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
Git是在這裏:
> which git
/usr/bin/git
你檢查過,如果你的git版本是> =一個brew需要的(如果指定的話) – pedrorijo91
@ pedrorijo91它沒有。 – bfontaine
請運行'cd $(brew --prefix)&& git fetch && git reset --hard origin/master'然後再次運行'brew doctor'。 – bfontaine