I have a 2GB Git bare repo with 30000 commits. Unfortunally I have early added some large files over the years, which I now have cleaned up using git filter-branch
- see e.g. this link.
Identification of the culpits - see e.g. this link
I have also cleaned away many old "test try" branches using git branch -D BRANCH-NAME
. Now the fun starts :-)
In my bare repo it seems that git gc --aggressive --prune=yes
does not reduce the directory size of the bare repo, but if I clone the bare repo and run git gc --agressive --prune=yes
then my directory size drops to 50 MB (which is REALLY nice).
I have also tried this nice idea, but it does not show SHAs or any other lead on where to cut the knife.
I could really use your input on safely getting rid of my bare repo storage in a systematic way.
Further relevant links that I read, tried, but it did not help this, this, this