Files
orca/src/shared/git-fetch-auto-maintenance.ts
T
Neil 26224196f5 perf(worktrees): avoid auto-maintenance in create fetches (#8039)
* perf(worktrees): avoid auto-maintenance in create fetches

Git's opportunistic maintenance can keep an already-complete exact-base fetch open for seconds. Disable it per command for create-base refreshes only, leaving ordinary fetch maintenance and exact-ref freshness unchanged.

* docs(worktrees): explain create fetch maintenance scope

* test(worktrees): account for fetch config prefixes

* fix(worktrees): cover Git 2.29 auto maintenance
2026-07-10 02:31:47 -07:00

11 lines
354 B
TypeScript

// Why: Git 2.29 can auto-run commit-graph work before maintenance.auto became a gate.
// The other keys cover modern maintenance and legacy auto-gc without changing user config.
export const GIT_FETCH_SKIP_AUTO_MAINTENANCE_CONFIG_ARGS = [
'-c',
'maintenance.auto=false',
'-c',
'maintenance.commit-graph.auto=0',
'-c',
'gc.auto=0'
] as const