@tukusejssirs as I replied to @meijin, this package doesn't create those files. In fact, the entire purpose of nvm
is to not pollute your system node installation. With nvm
you install a local version of node
and npm
, with a local node_modules
for "globally" installed packages.
If for example I install a package globally:
nvm use 16 # Now using node v16.14.0
npm install -g pm2
It will install into my local node's node_modules
. For me that is: ~/.nvm/versions/node/v16.14.0/lib/node_modules/pm2/
. nvm
also put this on my PATH
so I have access to the global pm2
binary (and for that matter the npm and node binaries themselves): ~/.nvm/versions/node/v16.14.0/bin
.
Pinned Comments
tomwadley commented on 2020-09-04 22:14 (UTC) (edited on 2020-09-04 22:15 (UTC) by tomwadley)
Due to the way nvm is designed, you have to source it before you can use it:
You will probably want that in your shell startup file, e.g.:
See nvm.install or the upstream README for more details.