1

So the latest version of the GoogleMaps framework is 123MB, which causes all kinds of problems with GitHub's 100MB limit. I tried Large File Storage, but that doesn't work. So now I'm trying to ignore my Pods directory. I edited my .gitignore file to look like this:

# Xcode
.DS_Store
build/
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3
*.perspectivev3
!default.perspectivev3
*.xcworkspace
!default.xcworkspace
xcuserdata
profile
*.moved-aside
DerivedData
.idea/

# CocoaPods
#
# We recommend against adding the Pods directory to your .gitignore. However
# you should judge for yourself, the pros and cons are mentioned at:
# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
#
Pods/

But when I try to push, I still get the same file-too-large error from the GoogleMaps Pod. What am I missing?

EDIT: Here's the exact error for those that don't believe it:

File Pods/GoogleMaps/Frameworks/GoogleMaps.framework/Versions/A/GoogleMaps is 123.00 MB; this exceeds GitHub's file size limit of 100.00 MB
Dietrich Epp
  • 205,541
  • 37
  • 345
  • 415
soleil
  • 12,133
  • 33
  • 112
  • 183

3 Answers3

1

This is a GitHub problem.

You will need to make sure that the file is not in your repo at all. This means removing the file from all commits. Adding a file to .gitignore does not remove files from Git if you have already added them, and removing a file from the latest commit does not remove the file from the repo because the file still exists in the repo history (in other words, git rm does not help).

To completely remove the file, edit history. See: Completely remove file from all Git repository commit history

Community
  • 1
  • 1
Dietrich Epp
  • 205,541
  • 37
  • 345
  • 415
  • Thanks for the suggestion. I tried this: `git rm GoogleMaps -r` from the Pods directory. Terminal showed all the files getting removed. I then committed with all the files removed. However when I tried to push I still got the same error :/ – soleil Mar 30 '16 at 17:39
1

Try this

git update-index --assume-unchanged '/pods' then do git status just to make sure what we are going to commit. Now this time it should not include "pods" directory.

Hope this helps?

Gaurav KD
  • 21
  • 4
0

The .gitignore looks good to me. I can think of the following causes, why you are still hitting the 100MB limit:

  • you already added the Pods directory but did not commit it so far. In this case git rm --cached <filename> is your friend
  • you committed the Pods directory in an earlier commit. Since git uploads all intermediary changes between the remote version and the local version, the Pods directory would be uploaded, even if it was removed again in a more recent commit. In this case, the only way to remove the Pods directory from your history is git rebase.
Vogelsgesang
  • 684
  • 1
  • 4
  • 15