| commit | 6c7c574b4989c3336eec845059143faa74034939 | [log] [tgz] |
|---|---|---|
| author | Bowgo Tsai <bowgotsai@google.com> | Wed Jul 09 19:03:18 2025 +0800 |
| committer | Bowgo Tsai <bowgotsai@google.com> | Fri Jul 11 16:24:01 2025 +0800 |
| tree | a21a0a2cab61279c81ff1a5629dc08246104903f | |
| parent | a689e16eddf3cd22758b44ac621ea1b89432f76b [diff] |
repo_pull.py: Optimize pulls for shallow-cloned projects
The script would previously unshallow repositories
with a clone-depth set in the manifest, causing slow pulls.
This patch reads the clone-depth attribute and uses
`git fetch --depth` and `git checkout` for those specific projects,
avoiding the performance issue.
Bug: 429538153
Test: development/tools/repo_pull/repo_pull.py bash \
'{topic} is:open' -g {gerrit_host}
Change-Id: I10adf644cd5c0379d611145227b4a0046461a15c