1

I am using git-bash/mingw32 on win7 without admin privileges. I am trying to install npm on my F: usb drive:

I have tried the following:

/f/envs/r1 (master)
$ curl -L https://npmjs.org/install.sh | sh
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   193  100   193    0     0    193      0  0:00:01 --:--:--  0:00:01   193
100  6711  100  6711    0     0   4887      0  0:00:01  0:00:01 --:--:--  436k
npm cannot be installed without nodejs.
Install node first, and then try again.

I have not had any luck in finding a portable node executable for windows in my searches so far. How can I install node/npm here?

user1592380
  • 34,265
  • 92
  • 284
  • 515
  • See also [How to install NodeJS LTS on Windows as a local user (without admin rights)](/q/37029089) – cachius May 29 '22 at 14:15

1 Answers1

0

Just download the latest stable node.exe via this link for 64-bit or this link for 32-bit.

Then for npm you can download the latest release from here (it seems to be behind several versions though as of this writing) and unpack the zip/tgz to the same directory as the node.exe you just downloaded.

You should then be able to execute node and npm.

mscdex
  • 104,356
  • 15
  • 192
  • 153
  • The node msi installer did not work for me , probably because I do not have admin rights. I presume I need to add the folder for node.exe to the win7 environmental path variable? – user1592380 Oct 12 '14 at 18:31
  • Yes, you will need to add the path where you downloaded `node.exe`/`npm.cmd` to to `%PATH%` if you want to use them from somewhere other than that download directory. – mscdex Oct 12 '14 at 18:44