mac homebrew修改为国内的阿里源和中科院镜像

网友投稿 942 2022-08-22

mac homebrew修改为国内的阿里源和中科院镜像

mac homebrew修改为国内的阿里源和中科院镜像

最近发现homebrew-东西超级的慢,发现阿里的源很快,我这里分享一下我的修改过程:

# 替换brew.git:cd "$(brew --repo)"git remote set-url origin 替换homebrew-core.git:cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"git remote set-url origin 替换homebrew-bottles:echo 'export HOMEBREW_BOTTLE_DOMAIN=>> ~/.zshrcsource ~/.zshrc

速度超级的快,看我的日志:

(base) ➜ Documents brew update --verboseChecking if we need to fetch /usr/local/Homebrew...Checking if we need to fetch /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core...Fetching /usr/local/Homebrew...Fetching /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core...Updating /usr/local/Homebrew...Branch 'master' set up to track remote branch 'master' from 'origin'.Switched to and reset branch 'master'Your branch is up to date with 'origin/master'.Switched to and reset branch 'stable'Current branch stable is up to date.==> Downloading downloaded: /Users/admin/Library/Caches/Homebrew/portable-ruby-2.6.3_2.yosemite.bottle.tar.gz==> Pouring portable-ruby-2.6.3_2.yosemite.bottle.tar.gzAlready up-to-date.

类似地,还可以切换为中科院的镜像:

cd "$(brew --repo)" git remote set-url origin "$(brew --repo)/Library/Taps/homebrew/homebrew-core" git remote set-url origin update

如果出现了下面的日志,也可以靠更换镜像解决哈:

Error: Failure while executing; `git clone brew安装报错问题​​​.

版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。

上一篇:Android APK 更新之路(android什么意思)
下一篇:Android 反编译初探 应用是如何被注入广告的(android开发)
相关文章

 发表评论

暂时没有评论,来抢沙发吧~