pflag adapter for mango.
import (
"fmt"
"github.com/muesli/mango"
mpflag "github.com/muesli/mango-pflag"
"github.com/muesli/roff"
flag "github.com/spf13/pflag"
)
func main() {
flag.Parse()
manPage := mango.NewManPage(1, "mango", "a man-page generator").
WithLongDescription("mango is a man-page generator for Go.").
WithSection("Copyright", "(C) 2022 Christian Muehlhaeuser.\n"+
"Released under MIT license.")
flag.VisitAll(mpflag.PFlagVisitor(manPage))
fmt.Println(manPage.Build(roff.NewDocument()))
}