can't brew install node

后端 未结 12 1081
无人及你
无人及你 2020-12-13 06:35

I am trying to upgrade my node via homebrew but ran into a problem because I think I tried to download through the website. I am very new to terminal. I\'ve tried to search

12条回答
  •  误落风尘
    2020-12-13 07:01

    brew postinstall node or brew link --overwrite node doesn't seem to help.

    After several rounds of brew uninstall node and brew install node the following were the offending directories and files:

    sudo rm -r /usr/local/include/node
    sudo rm -r /usr/local/share/doc/node
    sudo rm -r /usr/local/lib/node_modules
    sudo rm /usr/local/lib/dtrace/node.d
    sudo rm /usr/local/share/man/man1/node.1
    sudo rm /usr/local/share/systemtap/tapset/node.stp
    

    After the offending files are removed brew will do all the proper linking with permissions for you.

    Likely permissions were set as root:wheel because of a past install with sudo or perhaps manual installation, etc.

提交回复
热议问题