diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2025-11-28 03:38:21 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2025-11-28 03:38:21 +0000 |
| commit | 3f74ababf338d65ac5e29e7eb5541ce416b7fe75 (patch) | |
| tree | 3e06696a1833db776a7d1908dd2812dcbe86f6a7 /src | |
| parent | c15215d704117d1035806e3b5f71afc19f5516a8 (diff) | |
add git http advertisment allow-reachable-sha1-in-want and allow-tip-sha1-in-want
Diffstat (limited to 'src')
| -rw-r--r-- | src/git/subprocess.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/git/subprocess.rs b/src/git/subprocess.rs index dac3ace..c95bce5 100644 --- a/src/git/subprocess.rs +++ b/src/git/subprocess.rs | |||
| @@ -30,6 +30,15 @@ impl GitSubprocess { | |||
| 30 | let repo_path = repo_path.as_ref(); | 30 | let repo_path = repo_path.as_ref(); |
| 31 | 31 | ||
| 32 | let mut cmd = Command::new("git"); | 32 | let mut cmd = Command::new("git"); |
| 33 | |||
| 34 | // GRASP-01 requirement: MUST include `allow-reachable-sha1-in-want` and | ||
| 35 | // `allow-tip-sha1-in-want` in advertisement and serve available oids. | ||
| 36 | // These config options must be passed before the command name. | ||
| 37 | cmd.arg("-c"); | ||
| 38 | cmd.arg("uploadpack.allowReachableSHA1InWant=true"); | ||
| 39 | cmd.arg("-c"); | ||
| 40 | cmd.arg("uploadpack.allowTipSHA1InWant=true"); | ||
| 41 | |||
| 33 | cmd.arg(service.command_name()); | 42 | cmd.arg(service.command_name()); |
| 34 | 43 | ||
| 35 | if advertise { | 44 | if advertise { |