0

I accidentally added a large .eps file to my repo and was unable to push to github.

I've added the directory containing the file to .gitignore and tried running

git rm -rf --cached .

And then pushing the repo, but it's still giving me

remote: error: GH001: Large files detected. You may want to try Git Large File 
Storage - https://git-lfs.github.com.
remote: error: Trace: 024db62abfc6a9ecb4771d5437bb9cdc
remote: error: See http://git.io/iEPt8g for more information.
remote: error: File _assets/ToroAds_ChrisTuck.eps is 903.72 MB; this exceeds GitHub's file size limit of 100.00 MB

Here is the contents of my .gitignore

/bower_components/
/node_modules/
/_assets/
Taylor Huston
  • 1,104
  • 3
  • 15
  • 31
  • 1
    Even if you remove the file from HEAD, it still exists in the commit. You need to change your history to remove it from the commit where it exists. – crashmstr May 05 '17 at 17:33
  • Did you try `git rm --cached file.eps`? This answer might help you out: http://stackoverflow.com/questions/1139762/ignore-files-that-have-already-been-committed-to-a-git-repository?noredirect=1&lq=1 – kawnah May 05 '17 at 17:43
  • @kawnah doing that won't help because the file is already in the history of the branch. It has to be removed from the history, just as crashmstr is saying. – eftshift0 May 05 '17 at 18:38
  • Possible duplicate of [How to remove/delete a large file from commit history in Git repository?](http://stackoverflow.com/questions/2100907/how-to-remove-delete-a-large-file-from-commit-history-in-git-repository) – Code-Apprentice May 06 '17 at 02:38

0 Answers0