我有一个巨大的git存储库(810mb),其中包含不应存在的大文件:位于文件夹build/java
中的用于分发的完整JRE归档。Git从历史记录中删除大文件
我试图删除这些文件,所以我跑:
git filter-branch --tree-filter 'rm -rf build/java' HEAD
我现在看到的消息:Your branch and 'origin/develop' have diverged, and have 414 and 414 different commits each, respectively. (use "git pull" to merge the remote branch into yours)
我不想跑git pull
,但我推到远程前github上的仓库我想看看版本库已经缩小了。
不幸的是,我仍然认为它是810mb。
我在做什么错?我如何缩小该存储库?
TIA!
我彻底推荐BFG:https://rtyley.github.io/bfg-repo-cleaner/。 –
[如何从Git存储库中的提交历史中删除/删除大文件?](http://stackoverflow.com/questions/2100907/how-to-remove-delete-a-large-file-from- commit-history-in-git-repository) –
@AndrewC - 不,这是在我按照你引用的问题提出的建议之后,所以这可能是后续问题,但不是重复的。请不要向下投票。 – isapir