fetch: support hideRefs to speed up connectivity checks
With roughly 800 remotes all fetching into their own refs/remotes/$REMOTE/* island, the connectivity check[1] gets expensive for each fetch on systems which lack sufficient RAM to cache objects. To do a no-op fetch on one $REMOTE out of hundreds, hideRefs now allows the no-op fetch to take ~30 seconds instead of ~20 minutes on a noisy, RAM-constrained machine (localhost, so no network latency): git -c fetch.hideRefs=refs \ -c fetch.hideRefs='!refs/remotes/$REMOTE/' \ fetch $REMOTE [1] `git rev-list --objects --stdin --not --all --quiet --alternate-refs' Signed-off-by: Eric Wong <e@80x24.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
dadc8e6dac
commit
c6ce27ab08
@ -38,7 +38,7 @@ static const char rev_list_usage[] =
|
||||
" --tags\n"
|
||||
" --remotes\n"
|
||||
" --stdin\n"
|
||||
" --exclude-hidden=[receive|uploadpack]\n"
|
||||
" --exclude-hidden=[fetch|receive|uploadpack]\n"
|
||||
" --quiet\n"
|
||||
" ordering output:\n"
|
||||
" --topo-order\n"
|
||||
|
Reference in New Issue
Block a user