执行pod setup 报错error: RPC failed; curl 18 transfer closed with outstanding read data remainin

2023-08-01,,

执行pod setup 报错
  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

看这提示大意为 ,远程链接意外中断,剩余数据未完成读取!

网上有很多朋友遇到这个问题,也给出了解决方案如:

1、修改postBuffer的默认值

taodeMacBook-Pro:~ tao$ git config --global http.postBuffer 524288000

进行修改后确认

taodeMacBook-Pro:~ tao$ git config --list
credential.helper=osxkeychain
http.postbuffer=524288000

2、链接 自己手机热点,再次执行pod setup 查看进度如下

发现并没有什么用 34.00 kib/s 慢点。。。。。。

3、不能这样下去呀,这摆明了结果又是失败,于是看见网上有朋友说是因为国外镜像已经修改[https://www.jianshu.com/p/daac08374f46](https://www.jianshu.com/p/daac08374f46

于是执行如下命令更换镜像地址

taodeMacBook-Pro:~ tao$ git clone https://git.coding.net/CocoaPods/Specs.git ~/.cocoapods/repos/master

然后再次执行

taodeMacBook-Pro:repos tao$ pod setup

发现自己走了弯路,原本以为是git clone的问题,便修改postBuffer的默认值等等操作,

浪费了很多时间,所以特此记录一下希望帮到遇到相同问题的小伙伴。

还有一点:再执行过程中保持网络畅通,切勿更换网络,易出现卡死状态

如果你执行还是失败可以去cocoapods国内镜像看看

执行pod setup 报错error: RPC failed; curl 18 transfer closed with outstanding read data remainin的相关教程结束。

《执行pod setup 报错error: RPC failed; curl 18 transfer closed with outstanding read data remainin.doc》

下载本文的Word格式文档,以方便收藏与打印。