]> git.ipfire.org Git - thirdparty/git.git/commit - builtin/fetch.c
fetch: after refetch, encourage auto gc repacking
authorRobert Coup <robert@coup.net.nz>
Mon, 28 Mar 2022 14:02:10 +0000 (14:02 +0000)
committerJunio C Hamano <gitster@pobox.com>
Mon, 28 Mar 2022 17:25:53 +0000 (10:25 -0700)
commit7390f05a3c674e354ba2f52632046fa0a5c3e501
tree2b4cd1de6a82779dfeb39a08ad845f5a1b5c36d5
parent011b7757279e52043a0398b0a3b1d497d8417daf
fetch: after refetch, encourage auto gc repacking

After invoking `fetch --refetch`, the object db will likely contain many
duplicate objects. If auto-maintenance is enabled, invoke it with
appropriate settings to encourage repacking/consolidation.

* gc.autoPackLimit: unless this is set to 0 (disabled), override the
  value to 1 to force pack consolidation.
* maintenance.incremental-repack.auto: unless this is set to 0, override
  the value to -1 to force incremental repacking.

Signed-off-by: Robert Coup <robert@coup.net.nz>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/fetch-options.txt
builtin/fetch.c
t/t5616-partial-clone.sh