参考:
https://segmentfault.com/a/1190000042740954?utm_source=sf-similar-article
git上传代码时报错:
fatal: Out of memory, malloc failed (tried to allocate 524288000 bytes)
处理办法:
打开cmd,依次输入:
git config --global pack.windowMemory 50m
git config --global http.postbuffer 524288000
git repack
或者修改本地的.gitconfig文件
[http]
postbuffer = 524288000
[pack]
windowMemory = 50m
再在cmd中输入git repack,回车。