我们有一个远程git仓库,其中没有文件大小限制,我们曾经将一个300MB的文件推送到该仓库中。随后我们意识到了这个问题并将该文件从仓库中删除。
同时,这个仓库也被添加到了github上。当我们试图将更改推送到github时,就会出现大文件错误提示。
为了解决这个问题,我尝试使用交互式的git rebase解决方案,在 如何从Git存储库中的提交历史记录中删除/删除大文件? 中提出,但在重新基础操作结束时,当我执行git status时,我最终得到以下结果。
如果我使用 git pull,那么我所删除的所有更改都会被带回 git 存储库。我该如何解决这个问题?
同时,这个仓库也被添加到了github上。当我们试图将更改推送到github时,就会出现大文件错误提示。
remote: error: File dir/filename is 312.27 MB; this exceeds GitHub's file size limit of 100 MB
为了解决这个问题,我尝试使用交互式的git rebase解决方案,在 如何从Git存储库中的提交历史记录中删除/删除大文件? 中提出,但在重新基础操作结束时,当我执行git status时,我最终得到以下结果。
[18:10:35] $ git status
On branch master
Your branch and 'origin/master' have diverged,
and have 8 and 24 different commits each, respectively.
(use "git pull" to merge the remote branch into yours)
如果我使用 git pull,那么我所删除的所有更改都会被带回 git 存储库。我该如何解决这个问题?