git-combine: add cli arg to tune how often git gc --aggressive runs
Created by: ggilmore
This pr makes git-combine periodically run git gc --aggressive
for maintenance purposes against the repository it's maintaining. The frequency of git gc --aggressive
is controlled by a new gc-ratio
command line argument, which defaults to running it roughly once every 3 days.
On dogfood, gitserver was unable to clone the gigarepo until git gc --aggressive
was manually run. As a result of repository size went from ~75 gigabytes to ~25 gigabytes.
Test plan
This change is for a utility command, and doesn't affect the main sourcegraph application.