Documentation
¶
Overview ¶
Package output centralizes result formatting (console, txt, json) for SwaggerVu.
Index ¶
- func Status(code int) string
- type Logger
- func (l *Logger) Banner(version string)
- func (l *Logger) Error(format string, a ...any)
- func (l *Logger) Good(format string, a ...any)
- func (l *Logger) Info(format string, a ...any)
- func (l *Logger) Progress(format string, a ...any)
- func (l *Logger) ProgressDone()
- func (l *Logger) Warn(format string, a ...any)
- type Sink
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Logger ¶
type Logger struct {
Quiet bool
// contains filtered or unexported fields
}
Logger writes human-readable status to stderr, keeping stdout pipe-clean.
func (*Logger) Progress ¶ added in v1.0.2
Progress draws a transient single-line status to stderr, overwriting the previous one (carriage return, no newline). It is a no-op when quiet or when stderr is not a TTY, keeping redirected/piped logs clean. Call ProgressDone to terminate the line. Safe for concurrent use.
func (*Logger) ProgressDone ¶ added in v1.0.2
func (l *Logger) ProgressDone()
ProgressDone terminates an active progress line with a newline so subsequent output starts cleanly. No-op if no progress line is active.
type Sink ¶
type Sink struct {
// contains filtered or unexported fields
}
Sink collects result lines and flushes them to stdout or a file.
Click to show internal directories.
Click to hide internal directories.