Adam Breslin
Adam Breslin

Reputation: 69

installation problem - nodejs-lts (exited 1603) - Error while running 'C:\ProgramData\chocolatey\lib\nodejs-lts\tools\chocolateyinstall.ps1'

I'm trying to create an android emulator for react-native, but I'm having some trouble installing some packages when I type in this command: choco install -y nodejs-lts openjdk11

You will find the above command at the following website: https://reactnative.dev/docs/environment-setup

nodejs-lts won't install for some reason. Do I have to uninstall nodejs and install nodejs-lts instead? Here is a screenshot of the error: enter image description here

Upvotes: 5

Views: 7588

Answers (3)

sarthak singh
sarthak singh

Reputation: 1

just open the power shell and run as administrator and the files will get installed

Upvotes: -1

Mansi sonawani
Mansi sonawani

Reputation: 1

check whether your system has C:\ProgramData, If not that means its hidden which is causing the system to throw the error, To fix- It is generally not recommended to alter some system files-nevertheless.First of all

open File Explorer options from Control Panel Then to View Tab. Uncheck "Hide protected Operating system files" and click on "Show hidden files and folders" Press Yes and then OK.

After this try to install it again and it'll work this time

Upvotes: -1

Peter Musembi
Peter Musembi

Reputation: 109

Uninstall NodeJS manually and then run the command again.

source

Upvotes: 1

Related Questions