I'm working in a fairly big git repository with around hundred active contributors - so lots of new branches and commits every day, and lots of deleted remotes after the developers merge their changes to trunk. After pushing to remote I'm constantly receiving warning:
remote: warning: The last gc run reported the following. Please correct the root cause
remote: and remove gc.log.
remote: Automatic cleanup will not be performed until the file is removed.
remote:
remote: warning: There are too many unreachable loose objects; run 'git prune' to remove them.
git fsck
at this point lists dozens of dangling commits. To remove dangling/unreachable objects I have tried:
git gc --prune=now
git prune
git gc
The following git fsck
only shows one dangling commit. Subsequent pushes display the same warning.
So I'm thinking I should also find and remove this gc.log
file to get rid of the warning. But I can't locate in on my machine. Is there some default location for it? Should its location be configured somewhere? Is the warning message misleading and there is in fact no such file on my machine?