I've try to run this:
sudo npm install npm@latest -g
to test
npm audi
t, but this command failed, I've got error:
npm ERR! path /usr/lib/node_modules/npm/node_modules/fs-write-stream-atomic
npm ERR! code EEXIST
npm ERR! errno -17
npm ERR! syscall mkdir
npm ERR! EEXIST: file already exists, mkdir '/usr/lib/node_modules/npm/node_modules/fs-write-stream-atomic'
npm ERR! File exists: /usr/lib/node_modules/npm/node_modules/fs-write-stream-atomic
npm ERR! Move it away, and try again.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-06-04T16_50_00_242Z-debug.log
to restore the state I need to install npm using dnf (I need to remove the npm then /usr/lib/node_modules and install npm again).
if I move the file (it's symlink) then I've got error:
npm ERR! code MODULE_NOT_FOUND
npm ERR! Cannot find module 'fs-write-stream-atomic'
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-06-04T18_09_09_479Z-debug.log
How can I install npm 6 on Fedora?