网上给出了很多一步到位的mac上安装Homebrew的方法,在自己的机器上都不能成功,
例如:
1. ruby -e "$(cur -fsSL https://raw.github.com/mxcl/homebrew/go)":
2. curl -L https://github.com/mxcl/homebrew/tarball/master | sudo tar xz --strip 1 -C homebrew
最后尝试了最原始的分步安装方法,成功了,过程如下:
1. 下载Homebrew的压缩包文件
https://codeload.github.com/Homebrew/homebrew/legacy.tar.gz/master
2. 解压到/usr/local/homebrew
3. 在".bash_profile"文件中更新路径配置(如果~下没有该文件,则运行touch '~/.bash_profile'):
export PATH = $PATH:/usr/local/homebrew/bin
4. 使之立即生效:
source ~/.bash_profile
到这步就成功了,唯一的问题就是第1步下载速度有点慢。
Please enjoy brew !