How to reduce the size of your git repo
To reduce the size of your repository let’s first look at how big is it:
$ du -sh .git 5.6M .git And then counting the objects in the repository:
$ git count-objects -vH count: 181 size: 916.00 KiB in-pack: 9817 packs: 5 size-pack: 3.64 MiB prune-packable: 30 garbage: 0 size-garbage: 0 bytes Then, we can use the git gc command to reduce the size:
$ git gc --aggressive Enumerating objects: 9773, done.
[Read More]