Error: EPERM: operation not permitted, unlink 'D:\Sources\**\node_modules\fsevents\node_modules\abbrev\package.json'

前端 未结 30 2357
囚心锁ツ
囚心锁ツ 2020-12-05 04:00

I just updated npm to 5.4.0.
Now, Whenever I want install a npm package I get the following error:

D:\\Sources\\DownloadCms\\Md         


        
30条回答
  •  佛祖请我去吃肉
    2020-12-05 04:38

    If you downgrade to 5.3 and still get the same error in Windows like me.
    After hours working with npm versions I found the following solution:

    1. Download latest recommended version of nodejs, these days is node-v6.11.3-x64
    2. Uninstall nodejs with it.
    3. Go to C:\Users\{YourUsername}\AppData\Roaming folder and delete npm and npm-cache folders
    4. Run installer of nodejs again and install it
    5 Update npm to 5.3 with npm i -g npm@5.3 command line

    Now you should use npm without any issues.

提交回复
热议问题