安装问题-nodejs -lts(已退出1603) - 运行时出错:

发布于 2025-01-23 03:25:48 字数 513 浏览 5 评论 0原文

我正在尝试为React-Native创建一个Android模拟器,但是当我输入此命令时,我在安装一些软件包时遇到了一些麻烦:choco install -y nodejs-lts openjdk11

您会发现上面的命令在以下网站上: https://reactnative.dev/docs/envoriranment-setup

nodejs nodejs -lts不会出于某种原因安装。我是否必须卸载nodejs并安装nodejs-lts?这是错误的屏幕截图:

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

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

微暖i 2025-01-30 03:25:48

手动卸载nodejs,然后再次运行命令。

source

Uninstall NodeJS manually and then run the command again.

source

长亭外,古道边 2025-01-30 03:25:48

检查您的系统是否具有C:\ programData,
如果不是那样,则意味着导致系统丢弃错误的隐藏,
修复 -
通常不建议更改某些系统文件 - 无用


然后查看选项卡。
取消选中“隐藏受保护的操作系统文件”,然后单击“显示隐藏的文件和文件夹”
按是,然后确定。

此后,尝试再次安装它,这次将起作用

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

余生一个溪 2025-01-30 03:25:48

只需打开电源外壳并作为管理员运行,文件将安装

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

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文