added ctl manuals

This commit is contained in:
2026-02-21 16:38:53 +02:00
parent 5244a8d82d
commit c6ce50308d
70 changed files with 11889 additions and 110 deletions
+49
View File
@@ -0,0 +1,49 @@
package main
import (
"fmt"
"os"
"time"
"github.com/spf13/cobra/doc"
"mstore/cmd/mstorectl/command"
)
func run() error {
var err error
os.Args[0] = "mstorectl"
util := command.NewUtil()
err = util.Build()
if err != nil {
return err
}
cmd := util.GetRooCmd()
now := time.Now()
header := &doc.GenManHeader{
Title: "mstore",
Section: "1",
Manual: "User commands",
Source: "mstorectl command",
Date: &now,
}
opts := doc.GenManTreeOptions{
Header: header,
Path: "./",
CommandSeparator: "-",
}
err = doc.GenManTreeFromOpts(cmd, opts)
if err != nil {
return err
}
return err
}
func main() {
err := run()
if err != nil {
fmt.Printf("err: %v\n", err)
}
}