Update bench usage text to match new force flags · Entire
Update bench usage text to match new force flags
aec7011→main·
Soph·2mo ago·1 file·+1 added/-1 removed
The parser already rejects --force with a migration hint, but the
usageError() string still listed it as a valid flag. Replace with
--force-with-lease and --force-blind so the help text matches what
the parser accepts.
Co-Authored-By: Claude Opus 4.7 (1M context) noreply@anthropic.com
Sessions
98799f8a9225View transcript
Changes
1
cmd/git-sync-bench
Mmain.go+1/-1
458 unmodified lines
460
461
462
462
463
464
465
458 unmodified lines
}
func usageError(message string) error {
usage := fmt.Sprintf("usage:\n %s --source-url <repo> [flags]\n\nflags:\n --scenario bootstrap|sync\n --repeat 3\n --work-dir /tmp/git-sync-bench\n --keep-targets\n --json\n --branch main,release\n --map main:stable\n --tags\n --force\n --prune\n --stats\n --measure-memory\n --max-pack-bytes 104857600\n --target-max-pack-bytes 104857600\n --protocol auto|v1|v2\n -v\n", os.Args[0])
usage := fmt.Sprintf("usage:\n %s --source-url <repo> [flags]\n\nflags:\n --scenario bootstrap|sync\n --repeat 3\n --work-dir /tmp/git-sync-bench\n --keep-targets\n --json\n --branch main,release\n --map main:stable\n --tags\n --force-with-lease\n --force-blind\n --prune\n --stats\n --measure-memory\n --max-pack-bytes 104857600\n --target-max-pack-bytes 104857600\n --protocol auto|v1|v2\n -v\n", os.Args[0])
if message == "" {
return errors.New(strings.TrimSpace(usage))
}
}
Mcmd/git-sync-bench/main.go+1/-1