老师,运行npx react-native init 的时候会报错
来源:2-3 创建项目

菲迪亚斯
2020-04-16
✔ Downloading template
✔ Copying template
✔ Processing template
⠋ Updating CocoaPods repositories (this may take a few minutes) remote: Enumera remote: Enumerating objects: 82072, done.
remote: Counting objects: 100% (82072/82072), done.
remote: Compressing objects: 100% (498/498), done.
error: RPC failed; curl 18 transfer closed with outstanding read data remaining
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
✖ Updating CocoaPods repositories (this may take a few minutes)
✖ Updating CocoaPods repositories (this may take a few minutes)
error Error: Failed to update CocoaPods repositories for iOS project.
Please try again manually: “pod repo update”.
CocoaPods documentation: https://cocoapods.org/
1回答
-
今朝
2020-04-17
可能需要先执行sudo gem install cocoapods,如果还是不行的话,
可以执行
npx @react-native-community/cli doctor
这个命令会检查你的开发环境中的错误,并尝试自动修复
00
相似问题