Documentation
¶
Index ¶
- func Emit[E Event](sink Sink, event E)
- func EmitContainerLogLine(sink Sink, line string)
- func EmitLog(sink Sink, message string)
- func EmitProgress(sink Sink, container, layerID, status string, current, total int64)
- func EmitStatus(sink Sink, phase, container, detail string)
- func EmitUserInputRequest(sink Sink, event UserInputRequestEvent)
- func EmitWarning(sink Sink, message string)
- func FormatEventLine(event any) (string, bool)
- type ContainerLogLineEvent
- type ContainerStatusEvent
- type Event
- type InputOption
- type InputResponse
- type LogEvent
- type PlainSink
- type ProgressEvent
- type Sender
- type Sink
- type SinkFunc
- type TUISink
- type UserInputRequestEvent
- type WarningEvent
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EmitContainerLogLine ¶
func EmitProgress ¶
func EmitStatus ¶
func EmitUserInputRequest ¶
func EmitUserInputRequest(sink Sink, event UserInputRequestEvent)
func EmitWarning ¶
func FormatEventLine ¶
FormatEventLine converts an output event into a single display line.
Types ¶
type ContainerLogLineEvent ¶
type ContainerLogLineEvent struct {
Line string
}
type ContainerStatusEvent ¶
type Event ¶
type Event interface {
LogEvent | WarningEvent | ContainerStatusEvent | ProgressEvent | UserInputRequestEvent | ContainerLogLineEvent
}
type InputOption ¶
type InputResponse ¶
type PlainSink ¶
type PlainSink struct {
// contains filtered or unexported fields
}
func NewPlainSink ¶
type ProgressEvent ¶
type Sender ¶
type Sender interface {
Send(msg any)
}
Sender abstracts Bubble Tea's Program.Send to keep TUISink decoupled and testable.
type UserInputRequestEvent ¶
type UserInputRequestEvent struct {
Prompt string
Options []InputOption
ResponseCh chan<- InputResponse
}
type WarningEvent ¶
type WarningEvent struct {
Message string
}
Click to show internal directories.
Click to hide internal directories.