79201997

Date: 2024-11-19 03:21:04
Score: 2
Natty:
Report link

Solving permissions problems, it's help us to install whithdout sudo:

On the command line, in your home directory, create a directory for global installations: mkdir -p ~/.npm-global/lib

Configure npm to use the new directory path: npm config set prefix '~/.npm-global'

In your preferred text editor, open or create a ~/.profile file and add this line: export PATH=~/.npm-global/bin:$PATH

On the command line, update your system variables: source ~/.profile

To test your new configuration, install a package globally without using sudo: npm install -g jshint

Reasons:
  • RegEx Blacklisted phrase (1): help us
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Helder Gonzaga