安装步骤
sudo vim /etc/hosts
199.232.28.133 raw.githubusercontent.com
/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"
选择中科大数据源
配置国内源
选择中科大数据源
安装成功
brew help测试是否安装成功
再手动替换一下中科大的镜像站
安装之后还是各种install,update的命令还是很慢,手动替换一下镜像就好了
// 替换 Homebrew git -C "$(brew --repo)" remote set-url origin https://mirrors.ustc.edu.cn/brew.git // 替换 Homebrew Core git -C "$(brew --repo homebrew/core)" remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git // 替换 Homebrew Cask git -C "$(brew --repo homebrew/cask)" remote set-url origin https://mirrors.ustc.edu.cn/homebrew-cask.git # 更新 brew update