jasongin / nvs

Node Version Switcher - A cross-platform tool for switching between versions and forks of Node.js
Other
2.74k stars 210 forks source link

Dose NVS works without administrator privilege #275

Open divyansh-tiwariHL opened 1 year ago

divyansh-tiwariHL commented 1 year ago

many companies provide admin protected laptops to there employees, So while working with node's nvm on these laptops developer requires admin credentials to switch the node version, also when it comes to debugging the code node path's are not provided in the environment path manager because of which IDE prompts error saying node is not install, then again admin privilege's are required to start the IDE in admin mode (Windows platform). In nvs have we resolved this admin privilege or not, if not can we plan for this, as this will benefit a lot of folks, including me.

jasongin commented 1 year ago

Yes. On Windows you can use the MSI package to do a user installation. It does not require admin privilege, and supports all functionality.

divyansh-tiwariHL commented 1 year ago

@jasongin Thanks for your suggestion. I use MSI installer for nvs and it worked, admin permission's are not required. But I am facing two things.

  1. after NVS installation I installed node 14.17.5 via my cmd, after checking the node installation via node --version which returned 14.17.5 , I went on to my VS code to start debugging my code, on VS code the default terminal is power shell , first on VS code terminal I tried nvs --version command which worked and provided me my nvs version number whish is 1.7.0 then I tried node --version, but to my surprise it said node is not reorganized, then I installed it again via NVS, so my fist ask is why this happened ?
  2. after installing node via nvs in vs code ternimal I started my debugger but it gave me error saying, image why is this the case, and what can I do to over come this, one solution that I think I can do is add path of node.js 14.17.5 manually from the nvs directory in my file manager. but that will not allow to change my node version to other versions for debugging purpose. Please let me know how to over come this.
divyansh-tiwariHL commented 1 year ago

@jasongin is there a vs code extension which on change vode version via nvs can change runtimeExecutable path in launch.json file, I think that can also be a solution for this.