0

In the process of updating my version of Angular from 5 to 6 something I did wrong and ended up getting the following errors:

npm WARN checkPermissions Missing write access to / usr / local / lib /node_modules/@angular/cli npm WARN checkPermissions Missing write access to / usr / local / lib / node_modules / @ angular npm WARN optional SKIPPING OPTIONAL DEPENDENCY: node-pre-gyp@^0.9.0 (node_modules / @ angular / cli / node_modules / fsevents / node_modules / node-pre-gyp): npm WARN optional SKIPPING OPTIONAL DEPENDENCY: ELOOP: too many symbolic links found, open '/usr/local/lib/node_modules/@angular/cli/node_modules/fsevents/node_modules/node-pre-gyp/npm-shrinkwrap.json' npm ERR! path / usr / local / lib / node_modules / @ angular / cli npm ERR! code ELOOP npm ERR! errno -62 npm ERR! syscall access npm ERR! ELOOP: too many symbolic links encountered, access '/ usr / local / lib / node_modules / @ angular / cli' npm ERR! A complete log of this run can be found in: npm ERR! /Users/pacozevallos/.npm/_logs/2018-05-10T16_23_40_078Z-debug.log 

In any case how can I delete it and reinstall it?

I have Node 8.11.1 and my sistem is MacOS High Sierra 10.13.4

Any idea how I can solve it?

0

1 Answer 1

1

I think, you're missing sudo.

Try this.

sudo npm uninstall -g @angular/cli sudo npm cache clean sudo npm i -g @angular/cli 

or, delete all npm module (global)

sudo rm -rf /usr/local/lib/node_modules/npm 

...and now reinstall node.js.

reference : https://docs.npmjs.com/getting-started/fixing-npm-permissions (If it is related permission - I think so)

Sign up to request clarification or add additional context in comments.

3 Comments

I have tried with sudo but I keep getting the error, I have vuleto to install node and I continue with the same. It really is frustrating. All for wanting to update my angular cli. I should mention that when I run ng -v I do not get any results.
Give a try : sudo rm -rf /usr/local/lib/node_modules/npm to remove all npm module then remove node.js and again install node.js. As maintained here github.com/nodejs/node/issues/9377#issuecomment-257298199
This has been very helpful, I had to remove all traces of node / node_modules and reinstalled as you said and it worked. Although I still do not understand how to delete node from the total (when I deleted some folders, node remained, in the end it is another topic) Thank you very much I will mark it as correct.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.