无法将超过100MB的文件推送到git hub [英] not able to push file more than 100mb to git hub

查看:137
本文介绍了无法将超过100MB的文件推送到git hub的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我这样做时,出现此错误
超过GitHub的文件大小限制为100 MB
有什么方法可以将超过100 MB的文件推送到git hub
我是试图推送一个114 MB的zip文件。
是否有任何简单的解决方法。
谢谢

解决方案

一般不会,因为这是GitHub中的有意限制。这个限制的原因是git(通用git,而不是GitHub)存储每个文件的每个版本。因此,对多个大文件进行修订会使回购膨胀,并增加存储库其他用户的克隆和读取次数(请参阅

GitHub推荐使用大文件的方式是使用大文件存储,它是


... Git的开放源代码扩展,允许您使用与任何其他文本相同的方式处理大型
文件



使用Git Large File Storage,您和版本库的贡献者
可以从Git命令行克隆大文件,打开pull请求,
并评论差异。这是将文件推送到大于100MB的
GitHub的理想解决方案。 =https://help.github.com/articles/versioning-large-files/>这里
)。



然而,这个选项是部分只有参与的用户和组织才可以使用。

在任何情况下,作为一般性建议(不一定与GitHub相关),最佳做法不会是与大文件一起工作,并考虑您的具体情况的其他替代方案。


I am getting this error when I do so exceeds GitHub's file size limit of 100 MB Is there any way that I can push files more than 100 mb to git hub I am trying to push a zip file which is 114 mb . Is there any simple work around for this. thank you

解决方案

Generally no as this is an intentional limitation in GitHub. The reason for this limitation is that git (general git, not GitHub) stores every version of each file. Therefore having multiple revisions of large files will make the repo bloat and increase the clone and fetch times for other users of a repository (see here).

The way GitHub recommends working with large files is using Large File Storage which is

... an open-source extension to Git that allows you to work with large files the same way as any other text

With Git Large File Storage, you and your repository's contributors can clone large files from the Git command line, open pull requests, and comment on the diffs. It's the ideal solution for pushing files to GitHub that are larger than 100 MB.

(see GitHub documentation here).

However, this option is part of an early access program and only available to participating users and organizations.

In any case, as a general recommendation (not necessarily related to GitHub) the best practice would be not to work with big files, and consider other alternatives to your specific case.

这篇关于无法将超过100MB的文件推送到git hub的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆