“错误”;错误线路长度8192iB“;何时使用git推送

“错误”;错误线路长度8192iB“;何时使用git推送,git,push,Git,Push,我使用VisualStudioTeamServices和git来存储源代码 我的游戏有大档案。 我将游戏代码保存在VisualStudioTeamServices中,没有收到错误。但最近,我添加了更多的大文件,问题开始出现 使用git push时,我收到以下错误: F:\Games\BarbarianSouls_v2>git push Counting objects: 19464, done. Delta compression using up to 4 threads. Compre

我使用VisualStudioTeamServices和git来存储源代码

我的游戏有大档案。 我将游戏代码保存在VisualStudioTeamServices中,没有收到错误。但最近,我添加了更多的大文件,问题开始出现

使用git push时,我收到以下错误:

F:\Games\BarbarianSouls_v2>git push
Counting objects: 19464, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (19457/19457), done.
fatal: protocol error: bad line length 8192iB | 3.24 MiB/s
fatal: sha1 file '<stdout>' write error: Broken pipe
error: failed to push some refs to 'https://gitlab.com/fabiobh/barbarian_souls.git'
但它不起作用,当显示492mb时上传停止,然后我尝试使用以下代码:

git config --global http.postBuffer 7242880000
但我犯了第一个错误:

fatal: protocol error: bad line length 8192iB

如何消除此错误?

如果推送由多个提交组成,您可以尝试在较小的批中推送提交,而不是包含所有提交的大推送。当我得到这个的时候为我工作

fatal: protocol error: bad line length 8192
信息。例如:

git push origin <commit hash>:master
git推送原点:master

不是答案,但我们可以问一下您的回购为何如此之大吗?如果二进制文件(例如图像)是原因,您是否可以不将这些文件保存在Git中?我有很多3d文件。我将它们添加到回购协议中,因为如果出于某种原因需要恢复它。我需要所有的3d文件。我使用Unity引擎。错误消息实际上是:“致命:协议错误:错误行长度8192”。我在推进一个包含大量二进制文件的大型存储库时也面临着这个问题。尚未找到解决方案。我将存储库分解为少量文件,它对我有效。我为每个git推送添加一个文件夹,我将存储库分解成少量文件,它对我很有用。我为每个git推送添加一个文件夹。
git push origin <commit hash>:master