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

相关推荐
Python私教11 小时前
AI 并行编码的 Worktree 生命周期:创建、隔离与安全回收
人工智能·git
互联网中的一颗神经元12 小时前
16 — 改写历史 rebase:搬家到新楼层,不是合并
git
互联网中的一颗神经元16 小时前
19 — 贮藏与清理:stash 是抽屉,gc 是打包箱
git
用户3301448676317 小时前
20 — 远程进阶:强制推送的保险绳——force-with-lease
git
Cooper2518 小时前
别急着改 Git 历史:rebase、cherry-pick、bisect 与 reflog 的安全操作顺序
git
刚入门的大一新生19 小时前
Linux-版本控制器Git
git
扶苏100219 小时前
同一个 Git 项目整出两份,切分支互不影响?两种方案实测
大数据·git·elasticsearch
ZJU_统一阿萨姆19 小时前
【Git】Github 开源许可证详解
git·开源·github
持敬chijing2 天前
PHP开发-环境搭建-安装phpstudy-vscode工具
开发语言·vscode·php
csdn_aspnet2 天前
Copilot能换成本地吗?VSCode接本地大模型本地化接入方案
ide·vscode·ai·ollama