【iOS安全】Macbook更换brew源
Macbook更换brew源
参考:https://blog.csdn.net/weixin_35757704/article/details/125554715
Macbook更换brew源为清华源
cd "$(brew --repo)"
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git
cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
git remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git
brew update
报错:cd: no such file or directory:
% cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
cd: no such file or directory: /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core
解决办法:
参考:https://sutune.me/2022/02/02/mac-homebrew-config/
如果提示目录不存在,直接手动创建即可
cd: no such file or directory: /usr/local/Homebrew/Library/Taps/homebrew/homebrew-coremkdir -p /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core