本文共 1022 字,大约阅读时间需要 3 分钟。
运行命令brew install pip3,结果界面一直卡在Updating Homebrew...上,有两种解决办法
方法一:直接关闭brew每次执行命令时的自动更新(推荐)
vim ~/.bash_profile# 新增一行export HOMEBREW_NO_AUTO_UPDATE=true
方法二:替换brew源
cd "$(brew --repo)"git remote set-url origin https://mirrors.ustc.edu.cn/brew.git#替换homebrew-core.gitcd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.gitbrew update# 备用地址-1cd "$(brew --repo)"git remote set-url origin https://git.coding.net/homebrew/homebrew.gitbrew update# 备用地址-2cd "$(brew --repo)"git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/brew.gitcd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew-core.gitbrew update
如果备用地址都不行,那就只能再换回官方地址了
#重置brew.gitcd "$(brew --repo)"git remote set-url origin https://github.com/Homebrew/brew.git#重置homebrew-core.gitcd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"git remote set-url origin https://github.com/Homebrew/homebrew-core.git
转载地址:http://vqmaa.baihongyu.com/