我运行了这个:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
我得到了提示:
==> This script will install:
/usr/local/bin/brew
/usr/local/share/doc/homebrew
/usr/local/share/man/man1/brew.1
/usr/local/share/zsh/site-functions/_brew
/usr/local/etc/bash_completion.d/brew
/usr/local/Homebrew
点击“返回”(回车按钮)后,我收到以下错误:
==> Downloading and installing Homebrew...
fatal: cannot copy '/usr/local/git/share/git-core/templates/hooks/pre-receive.sample' to '/usr/local/Homebrew/.git/hooks/pre-receive.sample': Permission denied
Failed during: git init -q
你有什么想法,我遇到了什么样的错误,应该怎么解决?对于我来说,这是第一次遇到这样的问题,所以不太清楚。
sudo chown -R $USER /usr/local
。 - joran