Documentation
¶
Index ¶
- func NormalizePrompt(prompt string) string
- func SetDisableProgress(disable bool)
- type ProgressBar
- func (p *ProgressBar) Abort(name string, err error)
- func (p *ProgressBar) Add(prompt, name string, size int64, reader io.Reader) io.Reader
- func (p *ProgressBar) Complete(name string, msg string)
- func (p *ProgressBar) Get(name string) *progressBar
- func (p *ProgressBar) Start()
- func (p *ProgressBar) Stop()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NormalizePrompt ¶
NormalizePrompt normalizes the prompt string.
func SetDisableProgress ¶ added in v0.0.3
func SetDisableProgress(disable bool)
SetDisableProgress disables the progress bar.
Types ¶
type ProgressBar ¶
type ProgressBar struct {
// contains filtered or unexported fields
}
ProgressBar is a progress bar.
func NewProgressBar ¶
func NewProgressBar(writers ...io.Writer) *ProgressBar
NewProgressBar creates a new progress bar.
func (*ProgressBar) Abort ¶ added in v0.0.2
func (p *ProgressBar) Abort(name string, err error)
Abort aborts the progress bar.
func (*ProgressBar) Complete ¶
func (p *ProgressBar) Complete(name string, msg string)
Complete completes the progress bar.
func (*ProgressBar) Get ¶ added in v0.0.4
func (p *ProgressBar) Get(name string) *progressBar
Get returns the progress bar.
Click to show internal directories.
Click to hide internal directories.