我正在尝试使用自制软件在mac上安装nodejs,但是当我运行命令时:
brew install node
我收到以下错误:
Beginning with 0.8.0, this recipe now comes with npm.
It appears you already have npm installed at /usr/local/lib/node_modules/npm.
To use the npm that comes with this recipe, first uninstall npm with
`npm uninstall npm -g`, then run this command again.
If you would like to keep your installation of npm instead of
using the one provided with homebrew, install the formula with
the `--without-npm` option.
但是当我跑步时:
sudo npm uninstall npm -g
我明白了:
sudo: npm: command not found
当我运行命令时npm
,我得到:
-bash: /usr/local/bin/npm: No such file or directory
所以我不确定它是否真的安装过。
我的节点版本是0.8.22(我不知道它来自哪里)。我应该如何将其更新到最新版本?
如果你使用自制软件,只需使用它而不是其他任何东西。我会首先尝试使用brew卸载。yiu还通过home-brew安装节点吗?
—
马克
如果
—
bmike
brew list
显示节点和npm,只需删除两个并重新开始?