当前位置: 首页 > 工具软件 > git-point > 使用案例 >

Mac OS下使用SourceTree Push到Github时出现 POST git-receive-pack (chunked) 的解决办法

陆浩博
2023-12-01

在Mac os环境下,使用SourceTree向Github push提交代码时,出现以下提示:
POST git-receive-pack (chunked)
google到相同问题:stackoverflow

I found that the problem may be files that are large. I had one update that would not push even though I had successful pushes up to that point. There was only one file in the commit but it happened to be 1.6M

So I added the following config change

git config http.postBuffer 524288000
To allow up to the file size 500M and then my push worked. It may have been that this was the problem initially with pushing a big repo over the http protocol.

在SourceTree>设置>远程仓库>编辑配置文件中,增加相应代码:

[http] 
        postBuffer = 524288000

重新push,记得耐心等待上传完成,如果时间过长,可以考虑重新上传:)
原因:
因为仓库过大导致出现POST git-receive-pack (chunked) ,那么即使重新修改了配置文件,仍然要耐心等待一定时间。
尤其是国内网络问题,大文件push到github往往需要较长时间。

 类似资料: