oclidocs

package
v0.0.0-...-d01b20f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GenDocsOption

type GenDocsOption func(*genDocsOptions)

GenDocsOption is a functional option to configure the GenDocs function

func WithoutBadge

func WithoutBadge() GenDocsOption

WithoutBadge option will remove shields.io badget that indicates compliance with the OpenCLI Spec prepended to markdown documents by default.

func WithoutFooter

func WithoutFooter() GenDocsOption

WithoutFooter option will remove the `generated by OpenCLI` footer appended to the documents by default.

type GenFile

type GenFile struct {
	Name     string
	Contents []byte
}

func Generate

func Generate(doc oclispec.Document, options ...GenDocsOption) ([]GenFile, error)

Generate generates documentation for the given OpenCLI document in the specified format. It accepts the OpenCLI document domain object and the desired output format for the documentation as parameters. It returns the generated documentation as a byte slice.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL