How do you reduce CI checkout time?
IntermediateProductionMonorepos, large files and repository performance
Answer
Use fetch-depth: 1 when history is not needed, filter: blob:none plus sparse checkout for monorepos, cache the repo (or a mirror) on self-hosted runners and reuse workspace via a reference clone.
- uses: actions/checkout@v4
with:
fetch-depth: 1
sparse-checkout: |
services/billing
libs
More on Monorepos, large files and repository performance
What are the main trade-offs of a monorepo?IntermediateHow do you make CI efficient in a monorepo?AdvancedHow do you onboard developers to a very large repo without a 30-minute clone?IntermediateWhat does Scalar do and when do you recommend it?Advanced`git status` takes 20 seconds in a big working tree. How do you fix it?AdvancedWhen should a team adopt Git LFS and when should it avoid it?Intermediate