git clone 或者是vscode clone 时遇到the remote end hung up unexpectedly

复制代码
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

使用git clone总是报错

查看原因有三种可能:要么是缓存不够,要么是网络不行,要么墙的原因。

如果是网络不行,可以配置git的最低速度和最低速度时间:

复制代码
git config --global http.lowSpeedLimit 0
git config --global http.lowSpeedTime 999999

【补充】文件太大的解决方法:

当clone或者push git项目时,文件太大也会出现fatal: The remote end hung up unexpectedly

此时需要修改.gitconfig配置文件,打开终端,执行指令:

git config http.postBuffer 524288000

将postBuffer的缓存设置为500M即可。

参考 https://blog.csdn.net/Cai_deLong/article/details/115255735

相关推荐
香吧香2 分钟前
GitHub Actions 详解
git
Madison-No729 分钟前
Git版本控制工具(三)
git
风别鹤20 小时前
Xcode pod ‘xxx/xxx.h‘ file not found
ide·macos·xcode
可乐_不渴21 小时前
【Linux】 项目自动化构建工具makefile&& 版本管理Git&&第一个程序
linux·git·自动化·1024程序员节
golang学习记1 天前
VS Code Agents 新快捷键:一键穿梭主编辑器与Agent窗口
vscode·编辑器
lzx_0021 天前
Linux 开发工具(六) 版本管理器git的简单使用
git·1024程序员节
jiangliushi61 天前
GPT-6.1 Sol 免费用:git status 里中文文件名变成一串数字乱?条命令改好
git·codex·1024程序员节
NamoAmitabha1282 天前
安装“编译器环境”(Android Studio)--deepseek--Cocos --Creator3.8.8
android·ide·android studio
import_random2 天前
[git]只有git,没有github, 如何工作
git·github
import_random2 天前
[git]先创建远程仓库or先创建本地项目
git·github