Documentation
¶
Index ¶
- type OutputFormat
- type Spinner
- type Writer
- func (w *Writer) Print(message string)
- func (w *Writer) PrintBox(message string, boxStyle lipgloss.Style)
- func (w *Writer) PrintCommand(command string)
- func (w *Writer) PrintData(data interface{})
- func (w *Writer) PrintError(message string)
- func (w *Writer) PrintHeading(heading string)
- func (w *Writer) PrintInfo(message string)
- func (w *Writer) PrintKeyValue(key, value string)
- func (w *Writer) PrintMonospace(text string)
- func (w *Writer) PrintSuccess(message string)
- func (w *Writer) PrintWarning(message string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OutputFormat ¶
type OutputFormat string
OutputFormat represents the output format.
const ( FormatAuto OutputFormat = "auto" FormatJSON OutputFormat = "json" FormatPlain OutputFormat = "plain" FormatStyled OutputFormat = "styled" )
type Spinner ¶
type Spinner struct {
// contains filtered or unexported fields
}
Spinner provides a loading animation.
func NewSpinner ¶
NewSpinner creates a new spinner.
type Writer ¶
type Writer struct {
// contains filtered or unexported fields
}
Writer handles output formatting and writing.
func NewStderr ¶
func NewStderr(format OutputFormat) *Writer
NewStderr creates a new output writer for stderr.
func NewStdout ¶
func NewStdout(format OutputFormat) *Writer
NewStdout creates a new output writer for stdout.
func (*Writer) PrintCommand ¶
PrintCommand outputs a command being executed.
func (*Writer) PrintData ¶
func (w *Writer) PrintData(data interface{})
PrintData outputs structured data.
func (*Writer) PrintError ¶
PrintError outputs an error message.
func (*Writer) PrintHeading ¶
PrintHeading outputs a heading.
func (*Writer) PrintKeyValue ¶
PrintKeyValue outputs a key-value pair.
func (*Writer) PrintMonospace ¶
PrintMonospace outputs text in monospace style.
func (*Writer) PrintSuccess ¶
PrintSuccess outputs a success message.
func (*Writer) PrintWarning ¶
PrintWarning outputs a warning message.
Click to show internal directories.
Click to hide internal directories.