Documentation
¶
Overview ¶
Package out provides the output formatting for the CLI
Index ¶
- func DisableColor()
- func GetShortDate(date string) string
- func InputSchema(v any) bool
- func IsSchemaMode() bool
- func Log(pretty string)
- func Print(data any, pretty string)
- func PrintError(err error)
- func Schema(v any) bool
- func SetInputSchema(v bool)
- func SetOutput(o string) error
- func SetupTerminalLog()
- func StopTerminalLog()
- func Table(data any, tableMaker func() []string)
- func TagText(name string, hexRGB string) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DisableColor ¶ added in v0.3.10
func DisableColor()
DisableColor disables color output called if the ESCAPE_NO_COLOR environment variable is set
func GetShortDate ¶ added in v0.3.0
GetShortDate returns the short date format of the given date
func InputSchema ¶ added in v1.0.0
InputSchema prints the JSON Schema for the input type and returns true if input-schema was requested Commands that accept stdin input should call this to show their expected input format
func IsSchemaMode ¶ added in v1.0.0
func IsSchemaMode() bool
IsSchemaMode returns true if the output mode is schema
func Schema ¶ added in v1.0.0
Schema prints the JSON Schema for the given type and returns true if in schema mode Commands should call this at the start and return early if it returns true
func SetInputSchema ¶ added in v1.0.0
func SetInputSchema(v bool)
SetInputSchema sets the input schema flag
Types ¶
This section is empty.