cmd/mbf: disable threshold by default

This is not very useful.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2026-01-26 00:05:01 +09:00
parent 8a86cf74ee
commit 3224a7da63

View File

@@ -62,11 +62,14 @@ func main() {
return
}
if cache, err = pkg.Open(ctx, msg, flagCures, base); err == nil {
if flagTShift < 0 || flagTShift > 31 {
flagTShift = 31
}
if flagTShift < 0 {
cache.SetThreshold(0)
} else if flagTShift > 31 {
cache.SetThreshold(1 << 31)
} else {
cache.SetThreshold(1 << flagTShift)
}
}
return
}).Flag(
&flagVerbose,
@@ -82,7 +85,7 @@ func main() {
"Directory to store cured artifacts",
).Flag(
&flagTShift,
"tshift", command.IntFlag(31),
"tshift", command.IntFlag(-1),
"Dependency graph size exponent, to the power of 2",
)