zoukankan      html  css  js  c++  java
  • chown: /usr/local: Operation not permitted问题解决

    转:https://blog.csdn.net/yemao_guyue/article/details/80575532

    在MAC上安装homebrew事先博客进行安装,根据步骤进行下去,同样在brew update的时候出现报错:Error: /usr/local must be writable! 错误,在该文章中也给出解决办法(sudo chown -R $(whoami) /usr/local),但是这种方法对于高版本的OS来说,是解决不了的,会报chown: /usr/local: Operation not permitted错误。

    后来在https://stackoverflow.com/questions/46459152/cant-chown-usr-local-for-homebrew-in-osx-10-13-high-sierra网页上给出了解决办法,下面简单总结一下:

    先卸载已安装的homebrew,命令如下:

    /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"
    然后重新安装:
    /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
     

    通过该方法直接获取最新的homebrew,出现预期效果。

    自己试过,在mac 10.13.5系统上ok

  • 相关阅读:
    Dictionaries and lists
    Looping and dictionaries
    Dictionary as a set of counters
    Dictionaries
    List exercise
    Lists and strings
    Copying lists
    Objects and values
    [luoguP1944] 最长括号匹配_NOI导刊2009提高(1)
    [luoguP1868] 饥饿的奶牛(DP)
  • 原文地址:https://www.cnblogs.com/shmily2018/p/9237790.html
Copyright © 2011-2022 走看看