简体   繁体   中英

ESlint global install mac root terminal error

Im trying to globally install ESlint on my mac running mojave 10.14.6 but everytime i run 'npm install -g eslint' i get this error:

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 (though this is not recommended).

Is there anyway to run terminal with root/admin permissions?

Have you tried sudo npm install -g eslint and entering your password?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM