
Eduardo Acevedo García
PreguntaHola cuando quiero instalar eslint me sale el siguiente error
eduardo@PC-ACEVEDO:/mnt/c/Users/Eduardo$ npm install -g eslint npm WARN checkPermissions Missing write access to /usr/lib/node_modules npm ERR! code EACCES npm ERR! syscall access npm ERR! path /usr/lib/node_modules npm ERR! errno -13 npm ERR! Error: EACCES: permission denied, access '/usr/lib/node_modules' npm ERR! [Error: EACCES: permission denied, access '/usr/lib/node_modules'] { npm ERR! errno: -13, npm ERR! code: 'EACCES', npm ERR! syscall: 'access', npm ERR! path: '/usr/lib/node_modules' npm ERR! } npm ERR! npm ERR! The operation was rejected by your operating system. npm ERR! It is likely you do not have the permissions to access this file as the current user npm ERR! npm ERR! If you believe this might be a permissions issue, please double-check the npm ERR! permissions of the file and its containing directories, or try running npm ERR! the command again as root/Administrator. npm ERR! A complete log of this run can be found in: npm ERR! /home/eduardo/.npm/_logs/2020-09-22T11_57_12_297Z-debug.log eduardo@PC-ACEVEDO:/mnt/c/Users/Eduardo$ ```
- sudo apt-get upgrade
- sudo apt-get update Luego mira a ver la version que tengas de noce con:
- node -v

Eduardo Acevedo García
Gracias @massimokris con sudo me funciono

Massimo Di Berardino
Hola @acevedoge1, prueba conectándote al usuario root antes de ejecutar el comando o directamente ejecutando
sudo npm install -g eslint

Cristofher Jumbo Jimenez
Tiene pinta de que es por culpa de node. Has descargado node? y antes tienes que "upgrade" y "update", los comandos son: