windows-10nvmnvm-windows

How to install nvm for windows 10 and set up for all users


Problem

I need to install nvm for windows 10 and have it work for my admin profile and my non admin profile. When I do all my programming it's with my regular user account. But to install things / admin stuff, I have to provide an admin account.

Details I downloaded and ran the latest installer from this repo:

install nvm for windows 10: https://github.com/coreybutler/nvm-windows

WHen I try to run the installer, I have to use my admin account. Windows prompts me for it and after I supply the creds, the setup completes without any issues. The problem is that nvm only works when I run a command window as my admin user ... but I need to be able to run nvm as my regular non priv. user as well.

So right now, when I open a "command" window as admin, i can run

Microsoft Windows [Version 10.0.19043.1348]
(c) Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>nvm --version

Running version 1.1.9.

But if I run command just as my regular user,

Microsoft Windows [Version 10.0.19043.1348]
(c) Microsoft Corporation. All rights reserved.

C:\Users\me>nvm --version
'nvm' is not recognized as an internal or external command,
operable program or batch file.

C:\Users\me>

Any tips would be appreciated.

EDIT 1

enter image description here

enter image description here


Solution

  • Used the registry editor to add 2 new string varaibles to the regular user's profile. Can't do it through the Control Panel GUI because I'm always forced to use elevated credentials to access the control panel. And then when I do edit the User's environment vars, it's for the admin account only. So now when I open up a command window and run the "set" command, it includes these two variables:

    NVM_HOME=C:\Users\<nonAdminUser>\AppData\Roaming\nvm
    NVM_SYMLINK=C:\Program Files\nodejs
    

    And now everything just works.