Why am I told to 'cd' when updating Homebrew? [duplicate]

浪子不回头ぞ 提交于 2019-12-06 04:31:04

问题


Since my latest update of Homebrew (to 1.0.0), instead of just seeing

Checking out v1.0.1 in /usr/local/Homebrew...

when I brew update or brew upgrade --all I now see

Checking out v1.0.1 in /usr/local/Homebrew...
To checkout v1.0.1 in /usr/local/Homebrew run:
  'cd /usr/local/Homebrew && git checkout v1.0.1

Is that an error I should do something about? What's going on here? Are updates no failing for me?


回答1:


I had the same problem. Found the solution in this question, which is very similar to yours:

cd $(brew --prefix)/Homebrew && git fetch && git reset --hard origin/master

It seemed to be caused by a difference in "prefix" and "repository" directories for homebrew.



来源:https://stackoverflow.com/questions/39639146/why-am-i-told-to-cd-when-updating-homebrew

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!