muesli / mango-coral

coral adapter for mango

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

mango-coral

Latest Release Build Status Go ReportCard GoDoc

coral adapter for mango.

Example

import (
	"fmt"

	mcoral "github.com/muesli/mango-coral"
	"github.com/muesli/roff"
	"github.com/muesli/coral"
)

var (
    rootCmd = &coral.Command{
        Use:   "mango",
        Short: "A man-page generator",
    }
)

func main() {
    manPage, err := mcoral.NewManPage(1, rootCmd)
    if err != nil {
        panic(err)
    }

    manPage = manPage.WithSection("Copyright", "(C) 2022 Christian Muehlhaeuser.\n"+
        "Released under MIT license.")

    fmt.Println(manPage.Build(roff.NewDocument()))
}

About

coral adapter for mango

License:MIT License


Languages

Language:Go 100.0%