Brew发现自动更新homebrew时卡住


Brew发现自动更新homebrew时卡住

博客说明

文章所涉及的资料来自互联网整理和个人总结,意在于个人学习和经验汇总,如有什么地方侵权,请联系本人删除,谢谢!

原因

因为我之前换过源,换成了是阿里的源,然后阿里的源没有cask,所以出错在这里

解决

换成中科大的源

// 替换brew.git:
cd "$(brew --repo)"
git remote set-url origin https://mirrors.ustc.edu.cn/brew.git

// 替换homebrew-core.git:
cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git

// 替换homebrew-cask.git:
cd "$(brew --repo)"/Library/Taps/homebrew/homebrew-cask 
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-cask.git

更新源

brew update

之后再次安装就解决了问题


原文链接:https://www.cnblogs.com/guizimo/p/13333999.html