linux - Node.js is installed but it's not usable -
i'm using debian 9.1.0 , have installed node.js downloading lts version linux binaries (x64)
.
from location (where installed node.js), can use it:
$ cd /home/<user>softwares/nodejs/ $ ./node -v # displays: v6.11.3
but when run outside location, like:
$ cd ~/ $ node -v
i got error:
bash: node: command not found
the solution found on internet: create symlink
sudo ln -s ~/softwares/nodejs/ /usr/local/bin/nodejs
doesn't me.
i'm sharing solution found based on comment of ken y-n.
i'm missing 2 steps:
update path
in .bashrc
using:
$ echo 'export path=$path:/home/<username>/softwares/nodejs/bin:$path' >> ~/.bashrc
run make install
$ cd ~/ $ make install
Comments
Post a Comment