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 天前
Git 完全指南 —— 第1章:Git 概览与版本控制演进
git
摇滚侠3 天前
IDEA 创建 Java 项目 手动整合 SSM 框架
java·ide·intellij-idea
noravinsc3 天前
关于Git Flow
git
霸道流氓气质3 天前
Trae IDE 新手入门指南
ide
蜜獾云3 天前
在Git中配置用户名和密码
git
scx_link3 天前
通过git bash在本地创建分支,并推送到远程仓库中
开发语言·git·bash
南大白3 天前
IntelliJ IDEA 运行时的 JVM 本地内存溢出崩溃
git
爱就是恒久忍耐3 天前
VSCode里如何比较2个branch
ide·vscode·编辑器
意法半导体STM323 天前
【官方原创】如何为STM32CubeMX2配置Visual Studio Code配置方案
vscode·stm32·单片机·嵌入式硬件·策略模式·stm32cubemx·嵌入式开发
码农小旋风3 天前
Claude Code 基础用法大全:对话、分析、修改、测试、Git 和工作流
人工智能·git·chatgpt·claude