aboutsummaryrefslogtreecommitdiffhomepage
path: root/cmd
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-07-31 13:16:36 +0900
committerOphestra <cat@gensokyo.uk>2026-07-31 13:16:36 +0900
commit4e41b9bc99c6e03228e570f614b792316514b9e0 (patch)
tree76ed13e2281a3c777a7250eb83778356d124229d /cmd
parent153c980a61c90d617f3eac55080c22dd068946c0 (diff)
cmd/mbf: all command
This is a convenience command to cure all registered packages to avoid relying on the test. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/mbf/main.go19
1 files changed, 19 insertions, 0 deletions
diff --git a/cmd/mbf/main.go b/cmd/mbf/main.go
index 6ddfb142..2312c818 100644
--- a/cmd/mbf/main.go
+++ b/cmd/mbf/main.go
@@ -682,6 +682,25 @@ func main() {
)
}
+ c.NewCommand(
+ "all",
+ command.UsageInternal,
+ func([]string) error {
+ all := rosa.Native().CollectAll()
+ a := make(pkg.Collect, len(all))
+ for i, h := range all {
+ _, a[i] = rosa.Native().Std().Load(h)
+ }
+ return cm.Do(func(cache *pkg.Cache) (err error) {
+ _, _, err = cache.Cure(&a)
+ if pkg.IsCollected(err) {
+ err = nil
+ }
+ return
+ })
+ },
+ )
+
{
var (
flagDump string