700字范文,内容丰富有趣,生活中的好帮手!
700字范文 > 解决homebrew install卡住问题

解决homebrew install卡住问题

时间:2022-11-05 09:08:23

相关推荐

解决homebrew install卡住问题

问题描述:执行homebrew install会卡住在homebrew update

解决方案:

在~/.bash_profile中增加以下配置即可解决homebrew update卡住

#关闭homebrew更新export HOMEBREW_NO_AUTO_UPDATE=true

有时候homebrew install安装某些包时还会出现包不存在或者安装失败,此种问题,可以尝试切换包更新源,执行如下命令即可,建议选择清华大学更新源

# 替换brew.git:$ cd "$(brew --repo)"# 中国科大:$ git remote set-url origin https://mirrors./brew.git# 清华大学:$ git remote set-url origin https://mirrors.tuna./git/homebrew/brew.git# 替换homebrew-core.git:$ cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"# 中国科大:$ git remote set-url origin https://mirrors./homebrew-core.git# 清华大学:$ git remote set-url origin https://mirrors.tuna./git/homebrew/homebrew-core.git# 替换homebrew-bottles:# 中国科大:$ echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors./homebrew-bottles' >> ~/.bash_profile$ source ~/.bash_profile# 清华大学:$ echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna./homebrew-bottles' >> ~/.bash_profile$ source ~/.bash_profile# 应用生效(可不执行):$ brew update

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。