无法从我的git历史记录中删除大文件

时间:2016-12-27 22:47:33

标签: git repository commit rm

我在Mac Sierra上使用Git 2.6.2。我想从我的git历史记录中删除几个大文件(我不想在Git中记录这些文件,因为它们太大了)。所以我试着跑步......

git filter-branch --prune-empty -d /tmp/dir1 \
  --index-filter "git rm --cached -f --ignore-unmatch t1.backup" \
  --tag-name-filter cat -- --all

导致

Cannot create a new backup.
A previous backup already exists in refs/original/
Force overwriting the backup with -f

然后当我运行我的git commit和push命令时,我得到了这个输出......

localhost:myproject davea$ git add .
localhost:myproject davea$ git commit -m 'My commit.'
On branch master
Your branch is ahead of 'origin/master' by 3 commits.
  (use "git push" to publish your local commits)
nothing to commit, working directory clean
localhost:myproject davea$ git push origin master
Counting objects: 41, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (41/41), done.
^Citing objects:  82% (34/41) 

似乎仍然在存储库中处理大文件(基于最后一行花费这么长时间的事实)。所以我不认为我已经从我的git history / repository中清除了我的大文件。我该怎么做?

0 个答案:

没有答案