[Koha-devel] Repack git repo

Jonathan Druart jonathan.druart at bugs.koha-community.org
Tue Apr 28 10:19:00 CEST 2020


Hi devs,

Some of you may know, we got an issue with our Koha gitlab repo, it
was not syncing because of too big (no detail here, but that did not
really make sense anyway). It seems that it is syncing now but we
removed all the branches that are not protected (so only master)

I had a new try at splitting our repo, removing the po files from the
core repo (https://wiki.koha-community.org/wiki/Git_Splitting_and_Shrinking).
It's not a trivial process as it requires several changes, but I
noticed that:

After a git clone: `git count-objects -vH` returns 3.67/4.23 GiB
(cannot remember the correct number, but high!)
After a repack [1]: ~755 MiB

The command I used: `git gc --aggressive --prune=now`

I think we should schedule that command on the git server (it took
around 3 hours on a small VPS) to reduce its size.

I am available if you need any helps for that task.

Cheers,
Jonathan

PS: you may need to increase the windowMemory value with: `git config
--global pack.windowMemory 256m`

[1] https://git-scm.com/docs/git-repack

Spoiler: After removing the po file, and a repack, the repo index size is 127MiB


More information about the Koha-devel mailing list