在更新或者安裝brew報root權限的錯誤
Running Homebrew as root is extremely dangerous and no longer supported.
As Homebrew does not drop privileges on installation you would be giving all
build scripts full access to your system.
解決:
sudo chown -R $(whoami) /usr/local
把/use/local的owner換成自己,就有write權限了
whoami就是一個命令,會echo當前登錄用戶的名字。比如erica,就直接
sudo chown -R erica /usr/local
然后在執行
brew install 或者 brew update 就可以了