Can't upgrade NPM because of conflicts

Request help with installing, configuring, or using Linux applications, programs, and software
arifur
Site Admin
Posts: 108
Joined: Tue Nov 15, 2011 5:12 pm

Can't upgrade NPM because of conflicts

Post by arifur » Sun May 20, 2018 5:39 am

Error
sudo pacman -Syu

Code: Select all

error: failed to commit transaction (conflicting files)
npm: /usr/lib/node_modules/npm/changelogs/CHANGELOG-5.md exists in filesystem
npm: /usr/lib/node_modules/npm/doc/cli/npm-audit.md exists in filesystem
npm: /usr/lib/node_modules/npm/doc/cli/npm-hook.md exists in filesystem
npm: /usr/lib/node_modules/npm/doc/cli/npm-install-ci-test.md exists in filesystem
npm: /usr/lib/node_modules/npm/html/doc/cli/npm-audit.html exists in filesystem
npm: /usr/lib/node_modules/npm/html/doc/cli/npm-hook.html exists in filesystem
npm: /usr/lib/node_modules/npm/html/doc/cli/npm-install-ci-test.html exists in filesystem
npm: /usr/lib/node_modules/npm/lib/audit.js exists in filesystem
npm: /usr/lib/node_modules/npm/lib/hook.js exists in filesystem
npm: /usr/lib/node_modules/npm/lib/install-ci-test.js exists in filesystem
npm: /usr/lib/node_modules/npm/lib/install/audit.js exists in filesystem
npm: /usr/lib/node_modules/npm/man/man1/npm-audit.1 exists in filesystem
npm: /usr/lib/node_modules/npm/man/man1/npm-hook.1 exists in filesystem
npm: /usr/lib/node_modules/npm/man/man1/npm-install-ci-test.1 exists in filesystem
npm: /usr/lib/node_modules/npm/node_modules/byte-size/LICENSE exists in filesystem

Solution

Code: Select all

sudo npm --global remove npm
sudo pacman -Syu
Even after this if any other conflicts reamain, deleting those files may solve the issue.

Return to “Applications”

Who is online

Users browsing this forum: No registered users and 0 guests