Repository navigation
feat(git): add pack.threads and pack.windowMemory options - #50
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #50 +/- ##
==========================================
+ Coverage 96.96% 96.97% +0.01%
==========================================
Files 6 6
Lines 2208 2218 +10
==========================================
+ Hits 2141 2151 +10
Misses 67 67 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Is this saying that the side effect of this change is that the config env vars will not be supported anymore or they weren't anyway before and providing the means to set them via the proxy is the right way? |
We already set a few others via the proxy, so I guess the flags are the way to go. |
f28c87d to
2e8aea8
Compare
|
@rolandjitsu rebased, but the rustls bump is needed - sent a PR for that as well.
You're asking if it takes away the ability of using In that case - no. It doesn't touch environment variables, so the container's GIT_CONFIG_* still reaches upload-pack. I was just explaining precedence, i.e. if both set the same option, the Does this sound reasonable? |
Sounds good. Thanks. |
pack-objects memory grows with threads times window size, so a clone burst on a large repo could OOM the proxy with git's defaults. Assisted-by: Claude:claude-opus-5-5
2e8aea8 to
a57ed20
Compare
What kind of change does this PR introduce?
Summary
Point 3 from #45, part 2:
--pack-threadsand--pack-window-memory, passed to upload-pack as-c pack.threads/-c pack.windowMemory. Unset = git defaults. Independent of #47.On the
GIT_CONFIG_*question: upload-pack inherits the proxy env today, so container-setGIT_CONFIG_*reaches it. Clone and fetch do not get it, becausefetch_cmdsets its ownGIT_CONFIG_COUNT, which replaces those entries. Nothing guarantees the inheritance, so these flags are the supported way.Tests
upload_pack_runs_with_pack_options: real git serves a pack with both options set, and the recorded argv carries both-cvalues. git rejects a badpack.*value, so the served pack also shows git accepted them.Checklist
cargo fmt --all --check,cargo clippy --all-targets --all-features --locked -- -D warnings,cargo test --all-featuresAssisted-by:trailer (see CONTRIBUTING.md / AGENTS.md)Breaking change?
No. New flags only; unset keeps current behavior.