一、替换Homebrew国内源(推荐)
cd "$(brew --repo)"
git remote set-url origin https://mirrors.ustc.edu.cn/brew.git
cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git
brew update
中科大源
https://mirrors.ustc.edu.cn/brew.git
https://mirrors.ustc.edu.cn/homebrew-core.git
清华源:
https://mirrors.tuna.tsinghua.edu.cn/git/brew.git
https://mirrors.tuna.tsinghua.edu.cn/git/homebrew-core.git
官方源:
https://github.com/Homebrew/brew.git
https://github.com/Homebrew/homebrew-core.git
coding源
https://git.coding.net/homebrew/homebrew.git
https://github.com/Homebrew/homebrew-core.git
二、更换homebrew-bottles并关闭Homebrew自动更新
在 ~/.bash_profile文件中新增两行
export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles'
export HOMEBREW_NO_AUTO_UPDATE=true
网友评论