美文网首页
更新或者安装brew时报错

更新或者安装brew时报错

作者: Erica0708 | 来源:发表于2017-06-22 15:49 被阅读0次

    在更新或者安装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 就可以了

    相关文章

      网友评论

          本文标题:更新或者安装brew时报错

          本文链接:https://www.haomeiwen.com/subject/pgefcxtx.html