mac brew install node 安装总是版本不对


现象:

yuwentekiMacBook-Pro:~ yuwen$ brew install node
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin16/rbconfig.rb:213: warning: Insecure world writable dir /usr/local/mysql/bin in PATH, mode 040777
==> Downloading https://homebrew.bintray.com/bottles/node-7.10.0.sierra.bottle.tar
Already downloaded: /Users/yuwen/Library/Caches/Homebrew/node-7.10.0.sierra.bottle.tar.gz
==> Pouring node-7.10.0.sierra.bottle.tar.gz
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Could not symlink bin/node
Target /usr/local/bin/node
already exists. You may want to remove it:
  rm '/usr/local/bin/node'

To force the link and overwrite all conflicting files:
  brew link --overwrite node

To list all files that would be deleted:
  brew link --overwrite --dry-run node

Possible conflicting files are:
/usr/local/bin/node
/usr/local/share/man/man1/node.1
/usr/local/lib/dtrace/node.d
==> Using the sandbox
==> Caveats
Bash completion has been installed to:
  /usr/local/etc/bash_completion.d
==> Summary
 /usr/local/Cellar/node/7.10.0: 3,078 files, 39.7MB
yuwentekiMacBook-Pro:~ yuwen$ node --version
v0.10.22



解决:

1、brew uninstall node

2、删除链接文件

rm '/usr/local/bin/node'

rm '/usr/local/share/man/man1/node.1'

rm '/usr/local/lib/dtrace/node.d'

3、brew install node 




评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值