How do I completely uninstall Node.js, and reinstall from beginning (Mac OS X)

前端 未结 28 2203
难免孤独
难免孤独 2020-11-21 05:28

My version of node is always v0.6.1-pre even after I install brew node and NVM install v0.6.19.

My node version is:



        
28条回答
  •  迷失自我
    2020-11-21 06:07

    • Delete node and/or node_modules from /usr/local/lib

            ex code:
            cd /usr/local/lib
            sudo rm -rf node
            sudo rm -rf node_modules
      
    • Delete node and/or node_modules from /usr/local/include

    • Delete node, node-debug, and node-gyp from /usr/local/bin
    • Delete .npmrc from your home directory (these are your npm settings, don't delete this if you plan on re-installing Node right away)
    • Delete .npm from your home directory
    • Delete .node-gyp from your home directory
    • Delete .node_repl_history from your home directory
    • Delete node* from /usr/local/share/man/man1/
    • Delete npm* from /usr/local/share/man/man1/
    • Delete node.d from /usr/local/lib/dtrace/
    • Delete node from /usr/local/opt/local/bin/
    • Delete node from /usr/local/opt/local/include/
    • Delete node_modules from /usr/local/opt/local/lib/
    • Delete node from /usr/local/share/doc/
    • Delete node.stp from /usr/local/share/systemtap/tapset/

提交回复
热议问题