Jasper Ji

开口不在舌头上

0%

Brew实践

Mac上安装软件基本上都在使用Brew,做一些记录。

###常用命令

brew info 有些软件长时间不用了,记不起来命令的使用,用这个可以查到如何使用。

###常见问题

更新慢

执行brew update时很慢的问题,主要是是Github访问慢的缘故,设置从镜像拉取,基本上可以解决这个问题。用了中科大的源,亲测速度感刚的。

替换brew.git
1
2
cd "$(brew --repo)"
git remote set-url origin https://mirrors.ustc.edu.cn/brew.git
替换homebrew-core.git
1
2
cd "$(brew --repo)"/Library/Taps/homebrew/homebrew-core
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git
替换homebrew-cask.git
1
2
cd "$(brew --repo)"/Library/Taps/homebrew/homebrew-cask
git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-cask.git

参考

brew update 更新时 shallow clone
mac使用brew update无反应,更新慢解决办法