terminal

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsTerminal

func IsTerminal(w io.Writer) bool

IsTerminal reports whether w is a terminal.

Types

type Spinner

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

func NewSpinner

func NewSpinner(out io.Writer, label string) *Spinner

func (*Spinner) Start

func (s *Spinner) Start()

func (*Spinner) Stop

func (s *Spinner) Stop()

type StopOnWriteWriter

type StopOnWriteWriter struct {
	W       io.Writer
	Spinner *Spinner
	// contains filtered or unexported fields
}

StopOnWriteWriter wraps a writer and stops the spinner on the first write.

func (*StopOnWriteWriter) Write

func (s *StopOnWriteWriter) Write(p []byte) (int, error)

Jump to

Keyboard shortcuts

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