From 25858c8b16264beca64bf22b91588fa6694b2b07 Mon Sep 17 00:00:00 2001 From: Gavin Mak Date: Mon, 21 Jul 2025 12:24:41 -0700 Subject: sync: Default to interleaved mode The previous default, "phased" sync (separate network and checkout phases), can now be selected with `--no-interleaved`. Bug: 421935613 Bug: 432082000 Change-Id: Ia8624daa609a28ea2f87f8ea4b42138d8b3e9269 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/489681 Reviewed-by: Scott Lee Tested-by: Gavin Mak Commit-Queue: Gavin Mak --- subcmds/sync.py | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/subcmds/sync.py b/subcmds/sync.py index 13a322bc..b02fdd02 100644 --- a/subcmds/sync.py +++ b/subcmds/sync.py @@ -412,16 +412,18 @@ later is required to fix a server side protocol bug. type=int, metavar="JOBS", help="number of network jobs to run in parallel (defaults to " - "--jobs or 1). Ignored when --interleaved is set", + "--jobs or 1). Ignored unless --no-interleaved is set", ) p.add_option( "--jobs-checkout", default=None, type=int, metavar="JOBS", - help="number of local checkout jobs to run in parallel (defaults " - f"to --jobs or {DEFAULT_LOCAL_JOBS}). Ignored when --interleaved " - "is set", + help=( + "number of local checkout jobs to run in parallel (defaults " + f"to --jobs or {DEFAULT_LOCAL_JOBS}). Ignored unless " + "--no-interleaved is set" + ), ) p.add_option( @@ -480,7 +482,14 @@ later is required to fix a server side protocol bug. p.add_option( "--interleaved", action="store_true", - help="fetch and checkout projects in parallel (experimental)", + default=True, + help="fetch and checkout projects in parallel (default)", + ) + p.add_option( + "--no-interleaved", + dest="interleaved", + action="store_false", + help="fetch and checkout projects in phases", ) p.add_option( "-n", -- cgit v1.2.3-54-g00ecf