美文网首页
MacOS 解决Homebrew卡慢问题

MacOS 解决Homebrew卡慢问题

作者: 炎鸿 | 来源:发表于2019-10-10 14:07 被阅读0次

一、替换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

相关文章

网友评论

      本文标题:MacOS 解决Homebrew卡慢问题

      本文链接:https://www.haomeiwen.com/subject/xboopctx.html