mac brew update 卡着不动的问题

时间:2019-08-30 20:18:40   收藏:0   阅读:556

在升级 ruby的时候,使用了如下命令

curl -L https://get.rvm.io | bash -s stable --ruby

结果提示 : you need to make "brew update" avalabile.

我试了一下,果然 “brew update” 卡着不动。执行以下命令切换 brew 源。

第一步,替换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

此时执行“brew update” ok 了。

原文:https://www.cnblogs.com/demingblog/p/11436602.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!