1

Hello I am currently trying to grab the latest version of npm and I am trying to follow the directions from https://www.npmjs.com/package/npm-windows-upgrade in order to get the latest version, but when I get to the step 'npm install --global --production npm-windows-upgrade' it just hangs for hours and does nothing.

https://i.sstatic.net/vUABb.jpg

any help would be appreciated

5
  • what is the output now if you type npm --version? Commented Aug 7, 2016 at 15:42
  • @andrerpena 2.15.8 is what I am currently at and I did as you recommended below and it is still doing the same as before Commented Aug 7, 2016 at 16:11
  • then I'd strongly suggest you to downloadi the MSI installer from the website. This will definitely upgrade your version. After that, please try to do it using this NPM package and let's see if that's because you are using a too old version. Let me know of the result Commented Aug 7, 2016 at 16:13
  • nodejs.org/en/download/current Commented Aug 7, 2016 at 16:13
  • thanks for the help! but now I am stuck on '[ ..............] | loadRequestedDeps: sill install loadAllDepsIntoIdealTree' I dont know if thats supposed to take a while though.. and this came after running the upgrade tool Commented Aug 7, 2016 at 16:37

1 Answer 1

2

Just to make it clear, you're not having trouble running npm-windows-upgrade to upgrade your npm version. You're having trouble installing the upgrade tool.

First, make sure you are running PS as an administrator. If that doesn't help, you should probably look at the section fix-an-attempted-upgrade from their readme.md:

Fix an Attempted Upgrade

Chances are that you attempted to upgrade npm before, it somehow failed, and you then went looking for this tool. If the tool fails to upgrade, it may be troubled by partial changes done during npm install npm or npm upgrade npm. In that case, you will have to completely uninstall Node:

  • Uninstall Node.js (select Uninstall, not the Repair option).
  • Go into %programfiles%\nodejs and delete the entire folder.
  • Delete %appdata%\npm and %appdata%\npm-cache.
  • Edit your PATH and remove everything that references npm (to do so, hit "Start" and search for "Environment Variables").
  • Reinstall Node, then install this tool - and only use this tool to upgrade npm, do not attempt to run npm install npm.

PS: There's also a chance that you're running an NPM version that is too old be be compatible with installing npm-windows-upgrade, but I'm saying that based on nothing.

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

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.