Documentation ¶
Index ¶
- Variables
- type MockProgressIndicator
- type MockPrompter
- type PlainProgress
- type ProgressIndicator
- type PromptUIPrompter
- type Spinner
- type SpinnerProgressIndicator
- func (s *SpinnerProgressIndicator) Canceled(msg string)
- func (s *SpinnerProgressIndicator) Fail(msg string)
- func (s *SpinnerProgressIndicator) ShowSpinner(ss bool)
- func (s *SpinnerProgressIndicator) Start(msg string)
- func (s *SpinnerProgressIndicator) Stop()
- func (s *SpinnerProgressIndicator) Success(msg string)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( IconCheckmark = "\u2714" IconMultiplication = "\u274C" IconMinus = "\u2212" IconArrowRight = "\u2B95" IconExclamation = "\u0021" IconCircleSlash = "\u2298" IconSuccess = color.GreenString(IconCheckmark) IconError = color.YellowString(IconExclamation) // We display "warning" symbol to avoid scary "red" colors IconUnsupported = color.RedString(IconCircleSlash) )
Unicode characters https://unicode-table.com/en/
Functions ¶
This section is empty.
Types ¶
type MockProgressIndicator ¶
type MockProgressIndicator struct { Msg string // contains filtered or unexported fields }
func NewMockProgressIndicator ¶
func NewMockProgressIndicator() *MockProgressIndicator
func (*MockProgressIndicator) Canceled ¶ added in v0.36.0
func (s *MockProgressIndicator) Canceled(m string)
func (*MockProgressIndicator) Fail ¶
func (s *MockProgressIndicator) Fail(string)
func (*MockProgressIndicator) ShowSpinner ¶ added in v0.43.0
func (s *MockProgressIndicator) ShowSpinner(b bool)
func (*MockProgressIndicator) Start ¶
func (s *MockProgressIndicator) Start(string)
func (*MockProgressIndicator) Stop ¶
func (s *MockProgressIndicator) Stop()
func (*MockProgressIndicator) Success ¶
func (s *MockProgressIndicator) Success(string)
type MockPrompter ¶
type MockPrompter struct { PromptYesNoVal bool PromptMultiSelectAll bool PromptYesNoErr error PromptYesNoCallCount int PromptMultiSelectVal []string PromptMultiSelectErr error PromptMultiSelectCallCount int }
func NewMockPrompter ¶
func NewMockPrompter() *MockPrompter
func (*MockPrompter) MultiSelect ¶ added in v0.18.21
func (p *MockPrompter) MultiSelect(msg string, options []string) ([]string, error)
func (*MockPrompter) PromptYesNo ¶
func (p *MockPrompter) PromptYesNo(msg string) (bool, error)
type PlainProgress ¶ added in v0.18.19
type PlainProgress struct { }
func NewPlainProgress ¶ added in v0.18.19
func NewPlainProgress() *PlainProgress
func (*PlainProgress) Canceled ¶ added in v0.36.0
func (p *PlainProgress) Canceled(msg string)
func (*PlainProgress) Fail ¶ added in v0.18.19
func (p *PlainProgress) Fail(msg string)
func (*PlainProgress) ShowSpinner ¶ added in v0.43.0
func (p *PlainProgress) ShowSpinner(ss bool)
func (*PlainProgress) Start ¶ added in v0.18.19
func (p *PlainProgress) Start(msg string)
func (*PlainProgress) Stop ¶ added in v0.18.19
func (p *PlainProgress) Stop()
func (*PlainProgress) Success ¶ added in v0.18.19
func (p *PlainProgress) Success(msg string)
type ProgressIndicator ¶
type PromptUIPrompter ¶
type PromptUIPrompter struct{}
func NewPromptUIPrompter ¶
func NewPromptUIPrompter() *PromptUIPrompter
func (*PromptUIPrompter) MultiSelect ¶ added in v0.18.21
func (p *PromptUIPrompter) MultiSelect(msg string, options []string) ([]string, error)
func (*PromptUIPrompter) PromptYesNo ¶
func (p *PromptUIPrompter) PromptYesNo(msg string) (bool, error)
type Spinner ¶
type Spinner struct {
*spinnerLib.Spinner
}
func NewSpinner ¶
func NewSpinner() *Spinner
type SpinnerProgressIndicator ¶ added in v0.43.0
type SpinnerProgressIndicator struct { *spinnerLib.Spinner // contains filtered or unexported fields }
func NewSpinnerProgressIndicator ¶ added in v0.43.0
func NewSpinnerProgressIndicator() *SpinnerProgressIndicator
func (*SpinnerProgressIndicator) Canceled ¶ added in v0.43.0
func (s *SpinnerProgressIndicator) Canceled(msg string)
func (*SpinnerProgressIndicator) Fail ¶ added in v0.43.0
func (s *SpinnerProgressIndicator) Fail(msg string)
func (*SpinnerProgressIndicator) ShowSpinner ¶ added in v0.43.0
func (s *SpinnerProgressIndicator) ShowSpinner(ss bool)
func (*SpinnerProgressIndicator) Start ¶ added in v0.43.0
func (s *SpinnerProgressIndicator) Start(msg string)
func (*SpinnerProgressIndicator) Stop ¶ added in v0.43.0
func (s *SpinnerProgressIndicator) Stop()
func (*SpinnerProgressIndicator) Success ¶ added in v0.43.0
func (s *SpinnerProgressIndicator) Success(msg string)
Click to show internal directories.
Click to hide internal directories.