遵循从git安装节点js的步骤。我正在运行kali linux 2016
# this way is best if you want to stay up to date
# or submit patches to node or npm
mkdir ~/local
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
. ~/.bashrc
# could also fork, and then clone your own fork instead of the official one
git clone git://github.com/joyent/node.git
cd node
./configure --prefix=~/local
make install
cd ..
git clone git://github.com/isaacs/npm.git
cd npm
make install # or `make link` for bleeding edge
我没有成功安装npm。因为错误就是那个命令
node
找不到。但我成功安装了节点。 甚至回应了这条道路。可能是什么问题
答案 0 :(得分:0)
Download NodeJS v8.4.0 (x64 Linux)
提取.tar.xz
> /opt/node
(例如)并创建一个用于使用的符号链接:
ln -s /opt/node/bin/node /usr/bin/node
ln -s /opt/node/bin/npm /usr/bin/npm