When I run
npm install -g grunt-cli I get output about install location:
/home/XXX/.nvm/versions/node/v8.11.4/bin/grunt -> /home/XXX/.nvm/versions/node/v8.11.4/lib/node_modules/grunt-cli/bin/grunt
although my node installation is in different folder:
Some time back, I installed node using
apt install, which installed Node.js 8.11.4. After it, I installed
nvm. I was not happy with it and I uninstalled both, deleted
~/.nvm directory. Now
npm install -g grunt-cli command creates
~/.nvm directory and does not add
/home/XXX/.nvm/versions/node/v8.11.4/bin/grunt to the path (as documentation states).
None of environment variables point to
Why npm uses some leftovers and does not install in location where node is?