Bitbucket is alarming that my Git repository is over 1 GB. Actually, in Repository details page it says it is 1.7 GB. That's crazy. I must have included large data files in the version control. My local repository is in fact 10 GB, which means that at least I have been using .gitignore
successfully to some extent to exclude big files from version control.
Next, I followed the tutorial here https://confluence.atlassian.com/display/BITBUCKET/Reduce+repository+size and tried to delete unused large data. The command files.git count-objects -v
at the top level folder of my repo
returned the following:
count: 5149
size: 1339824
in-pack: 11352
packs: 2
size-pack: 183607
prune-packable: 0
garbage: 0
size-garbage: 0
The size-pack 183607 KB is much smaller than 1.7 GB. I was a bit perplexed.
Next I downloaded the BFG Repo Cleaner https://rtyley.github.io/bfg-repo-cleaner and ran the command java -jar bfg-1.12.3.jar --strip-blobs-bigger-than 100M
at the top level directory to remove files bigger than 100 MB from all the not latest commits. However, BFG returned the following message:
Warning : no large blobs matching criteria found in packfiles
- does the repo need to be packed?
Repeating the same for 50M resulted in the same.
Does this mean that all the files larger than 50 MB are in the latest commit? In Source code browser in Bitbucket, I looked at folders that contain large data files but those files are not included (successfully ignored).
Could anyone explain briefly what is the source of confusion about the repository size and existence of large files in the repo?