简而言之,快使用中科大全家桶!!!
# Homebrew 源代码仓库替换为 USTC 镜像
cd "$(brew --repo)"
git remote set-url origin https://mirrors.ustc.edu.cn/brew.git
# Homebrew Bottles (二进制)源[针对 bash 用户的,zsh 同理]
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.ustc.edu.cn/homebrew-bottles' >> ~/.bash_profile
source ~/.bash_profile
# Homebrew Cask (界面程序)源替换为 USTC 镜像[但程序还是从开发者各自的地址下]
cd "$(brew --repo)"/Library/Taps/homebrew/homebrew-cask
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-cask.git
昨天发现了之后先放在博客上了,今天贴过来