ui

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: May 24, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

spinner.go implements the CLI spinner displayed while torque performs background work (captures, remotes, etc.).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsTerminalReader

func IsTerminalReader(r io.Reader) bool

func IsTerminalWriter

func IsTerminalWriter(w io.Writer) bool

func StartSpinner

func StartSpinner(w io.Writer, message string) func(success bool)

StartSpinner prints a lightweight ASCII spinner until the returned stop function is called. The stop function prints either "[done]" or "[fail]" depending on the success flag.

func TerminalWidth

func TerminalWidth(w io.Writer) (int, bool)

Types

type BuildConsole

type BuildConsole struct {
	// contains filtered or unexported fields
}

func NewBuildConsole

func NewBuildConsole(out io.Writer, meta BuildMetadata, opts BuildConsoleOptions) *BuildConsole

func (*BuildConsole) Done

func (c *BuildConsole) Done()

func (*BuildConsole) ObserveLog

func (c *BuildConsole) ObserveLog(rec tailer.LogRecord)

type BuildConsoleOptions

type BuildConsoleOptions struct {
	Enabled bool
	Width   int
}

type BuildMetadata

type BuildMetadata struct {
	ContextDir string
	Dockerfile string
	Tags       []string
	Platforms  []string
	Mode       string
	Push       bool
	Load       bool
}

type DeployConsole

type DeployConsole struct {
	// contains filtered or unexported fields
}

func NewDeployConsole

func NewDeployConsole(out io.Writer, meta DeployMetadata, opts DeployConsoleOptions) *DeployConsole

func (*DeployConsole) Done

func (c *DeployConsole) Done()

func (*DeployConsole) EmitEvent

func (c *DeployConsole) EmitEvent(level, message string)

func (*DeployConsole) PhaseCompleted

func (c *DeployConsole) PhaseCompleted(name, status, message string)

func (*DeployConsole) PhaseStarted

func (c *DeployConsole) PhaseStarted(name string)

func (*DeployConsole) SetDiff

func (c *DeployConsole) SetDiff(string)

func (*DeployConsole) UpdateMetadata

func (c *DeployConsole) UpdateMetadata(meta DeployMetadata)

func (*DeployConsole) UpdateResources

func (c *DeployConsole) UpdateResources(rows []deploy.ResourceStatus)

type DeployConsoleOptions

type DeployConsoleOptions struct {
	Enabled         bool
	Wide            bool
	Width           int
	DetailsExpanded bool
}

type DeployMetadata

type DeployMetadata struct {
	Release         string
	Namespace       string
	Chart           string
	ChartVersion    string
	ValuesFiles     []string
	SetValues       []string
	SetStringValues []string
}

Jump to

Keyboard shortcuts

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