Clean up README structure · Entire
Clean up README structure
Sessions
Changes
1
- MREADME.md+51/-52
40 unmodified lines
Usage
Quick Start
go run ./cmd/git-sync sync
Commands
Plan a sync without pushing anything:
<target-url>
Benchmarking
For repeated benchmark runs, prefer the dedicated benchmark command instead of manually wrapping git-sync invocations:
- For large-repo measurements, use a local bare mirror as the source so the benchmark reflects
git-syncbehavior rather than internet variance. See docs/benchmarking.md for details.
Sync Behavior
When sync sees that all managed target refs are absent and the run is compatible with bootstrap semantics, it automatically uses the bootstrap relay path instead of the normal decode-and-repack sync path.
<source-url>
JSON Output
Add --json to probe, fetch, bootstrap, plan, or sync to emit machine-readable output instead of the default text format.
Auth
For GitHub and similar providers, use basic auth with a token as the password.
Relevant variables:
GITSYNC_SOURCE_TOKENGITSYNC_TARGET_TOKENGITSYNC_SOURCE_USERNAMEdefault:git
Behavior
Protocol Notes
- Source refs are listed with
GET /info/refs?service=git-upload-pack. - When the source supports it, the client can negotiate protocol v2 with
Git-Protocol: version=2, then usels-refsandfetch.
Testing
GITSYNC_SOURCE_INSECURE_SKIP_TLS_VERIFY=trueGITSYNC_TARGET_INSECURE_SKIP_TLS_VERIFY=true
Planned Bootstrap Path
Design Notes
There is a dedicated bootstrap command path for large initial syncs into an empty target. The intent is to relay a fetched source pack directly into target receive-pack instead of decoding the full object graph into local memory first.