Documentation
¶
Overview ¶
Package progress provides progress reporting for long-running operations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AutoEnabled ¶
AutoEnabled reports whether terminal progress output is appropriate.
Types ¶
type CountingTerminal ¶
type CountingTerminal struct {
// contains filtered or unexported fields
}
CountingTerminal is a progress bar for counting operations where the total isn't known upfront.
func NewCountingTerminal ¶
func NewCountingTerminal(op string, enabled bool) *CountingTerminal
NewCountingTerminal creates a new counting terminal progress bar.
func (*CountingTerminal) Done ¶
func (t *CountingTerminal) Done(finalMessage string)
Done marks the operation as complete.
func (*CountingTerminal) Increment ¶
func (t *CountingTerminal) Increment()
Increment advances the counter.
func (*CountingTerminal) SetEnabled ¶
func (t *CountingTerminal) SetEnabled(enabled bool)
SetEnabled enables or disables the progress bar.
type Progress ¶
Progress tracks operation progress.
type Terminal ¶
type Terminal struct {
// contains filtered or unexported fields
}
Terminal provides a terminal-based progress bar.
func NewTerminal ¶
NewTerminal creates a new terminal progress bar.
func (*Terminal) SetEnabled ¶
SetEnabled enables or disables the progress bar.
Click to show internal directories.
Click to hide internal directories.