brew换源
admin
2024-03-24 00:34:51

查看 brew.git 当前源

$ cd “$(brew --repo)” && git remote -v
origin https://github.com/Homebrew/brew.git (fetch)
origin https://github.com/Homebrew/brew.git (push)

查看 homebrew-core.git 当前源

$ cd “$(brew --repo homebrew/core)” && git remote -v
origin https://github.com/Homebrew/homebrew-core.git (fetch)
origin https://github.com/Homebrew/homebrew-core.git (push)

修改 brew.git 为阿里源

$ git -C “$(brew --repo)” remote set-url origin https://mirrors.aliyun.com/homebrew/brew.git

修改 homebrew-core.git 为阿里源

$ git -C “$(brew --repo homebrew/core)” remote set-url origin https://mirrors.aliyun.com/homebrew/homebrew-core.git

zsh 替换 brew bintray 镜像

$ echo ‘export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.aliyun.com/homebrew/homebrew-bottles’ >> ~/.zshrc
$ source ~/.zshrc

bash 替换 brew bintray 镜像

$ echo ‘export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.aliyun.com/homebrew/homebrew-bottles’ >> ~/.bash_profile
$ source ~/.bash_profile

刷新源

$ brew update

相关内容

热门资讯

17道 特色旺销菜 恰恰茄子 原料: 糯长茄200克,香菜3克。 调料: 秘制茄子酱40克。 制作: 1.将长茄去皮后...
西藏攻略:7天6晚经典路线,带... 每年5月至10月,是西藏的季节,也是游客最多的时段。最近我们收到很多朋友的咨询:“次来西藏,只有7天...