Speed up cloning in initial install
Summary
Implement an automated solution to improve GDK clone performance while maintaining full Git functionality by either implementing parallel source file download with background .git backfilling.
Problem
Currently, GDK users face a trade-off between clone speed and Git functionality:
- Full clones: Provide complete Git functionality but take ~10 minutes to clone
-
Blobless clones: Clone faster (~4 minutes) but cause significant slowdowns and failures with Git commands like
git blame,git log -S, andgit push
Multiple team members have reported issues with blobless clones, including:
-
git blametaking excessive time or failing with "fatal: You are attempting to fetch XYZ, which is in the commit graph file but not in the object database" - Git operations taking 8-10 minutes due to on-demand blob fetching
- Productivity impacts for developers looking up older Git history
Proposal
A solution could be to:
- Download source files needed for GDK setup tasks immediately (e.g. a shallow clone or archive download)
- Backfill the
.gitdirectory in parallel/background - Allows setup to proceed
- Wait for setup and backfill to finish before yielding back to the user’s shell
This would ensure that a full clone is available after setup but we are not wasting user time by blocking the setup from running.