Documentation
¶
Index ¶
- Constants
- Variables
- func Blue(text string) string
- func Bluef(text string, a ...interface{}) string
- func Bold(text string) string
- func Boldf(text string, a ...interface{}) string
- func ColoredString(text string) string
- func Cyan(text string) string
- func Cyanf(text string, a ...interface{}) string
- func Error(text string, a ...interface{})
- func ErrorBar(text string, a ...interface{})
- func ErrorBarIcon(text string, a ...interface{})
- func ErrorLine()
- func ErrorLineBottom()
- func ErrorLineText(text string, a ...interface{})
- func ErrorLineTextTop(text string, a ...interface{})
- func ErrorLineTop()
- func Fail(text string, a ...interface{})
- func Green(text string) string
- func Greenf(text string, a ...interface{}) string
- func Info(text string, a ...interface{})
- func InfoBar(text string, a ...interface{})
- func InfoBarIcon(text string, a ...interface{})
- func InfoLine()
- func InfoLineBottom()
- func InfoLineText(text string, a ...interface{})
- func InfoLineTextTop(text string, a ...interface{})
- func InfoLineTop()
- func PrintColored(text string, a ...interface{})
- func PrintColoredln(text string, a ...interface{})
- func Red(text string) string
- func Redf(text string, a ...interface{}) string
- func StartSpinners() (wg *sync.WaitGroup)
- func Success(text string, a ...interface{})
- func SuccessBar(text string, a ...interface{})
- func SuccessBarIcon(text string, a ...interface{})
- func SuccessLine()
- func SuccessLineBottom()
- func SuccessLineText(text string, a ...interface{})
- func SuccessLineTextTop(text string, a ...interface{})
- func SuccessLineTop()
- func VerboseError(text string, a ...interface{})
- func VerboseErrorBar(text string, a ...interface{})
- func VerboseFail(text string, a ...interface{})
- func VerboseInfo(text string, a ...interface{})
- func VerboseInfoBar(text string, a ...interface{})
- func VerboseSuccess(text string, a ...interface{})
- func VerboseSuccessBar(text string, a ...interface{})
- func VerboseWarning(text string, a ...interface{})
- func VerboseWarningBar(text string, a ...interface{})
- func WaitAllSpinners()
- func Warning(text string, a ...interface{})
- func WarningBar(text string, a ...interface{})
- func WarningBarIcon(text string, a ...interface{})
- func WarningLine()
- func WarningLineBottom()
- func WarningLineText(text string, a ...interface{})
- func WarningLineTextTop(text string, a ...interface{})
- func WarningLineTop()
- func Yellow(text string) string
- func Yellowf(text string, a ...interface{}) string
- type TaskSpinner
Constants ¶
View Source
const BlueColor = "\x1b[94m"
Blue is the blue color string constant
View Source
const BoldString = "\033[1m"
View Source
const CyanColor = "\x1b[36m"
View Source
const GreenColor = "\x1b[32m"
View Source
const NoColor = "\x1b[0m"
Nc is the no color string constant
View Source
const NoboldString = "\033[0m"
View Source
const RedColor = "\x1b[31m"
View Source
const YellowColor = "\x1b[33m"
Variables ¶
View Source
var ErrorIcon = "✗"
View Source
var InfoIcon = "🐧"
View Source
var SuccessIcon = "✔"
View Source
var Verbose = false
Enables verbose printing
View Source
var WarningIcon = "⚠"
Functions ¶
func ColoredString ¶ added in v0.1.3
func ErrorBarIcon ¶
func ErrorBarIcon(text string, a ...interface{})
func ErrorLineBottom ¶
func ErrorLineBottom()
func ErrorLineText ¶
func ErrorLineText(text string, a ...interface{})
func ErrorLineTextTop ¶
func ErrorLineTextTop(text string, a ...interface{})
func ErrorLineTop ¶
func ErrorLineTop()
func InfoBarIcon ¶
func InfoBarIcon(text string, a ...interface{})
func InfoLineBottom ¶
func InfoLineBottom()
func InfoLineText ¶
func InfoLineText(text string, a ...interface{})
func InfoLineTextTop ¶
func InfoLineTextTop(text string, a ...interface{})
func InfoLineTop ¶
func InfoLineTop()
func PrintColored ¶ added in v0.1.2
func PrintColored(text string, a ...interface{})
func PrintColoredln ¶ added in v0.1.2
func PrintColoredln(text string, a ...interface{})
func StartSpinners ¶ added in v0.2.1
func SuccessBar ¶
func SuccessBar(text string, a ...interface{})
func SuccessBarIcon ¶
func SuccessBarIcon(text string, a ...interface{})
func SuccessLine ¶
func SuccessLine()
func SuccessLineBottom ¶
func SuccessLineBottom()
func SuccessLineText ¶
func SuccessLineText(text string, a ...interface{})
func SuccessLineTextTop ¶
func SuccessLineTextTop(text string, a ...interface{})
func SuccessLineTop ¶
func SuccessLineTop()
func VerboseError ¶
func VerboseError(text string, a ...interface{})
func VerboseErrorBar ¶
func VerboseErrorBar(text string, a ...interface{})
func VerboseFail ¶
func VerboseFail(text string, a ...interface{})
func VerboseInfo ¶
func VerboseInfo(text string, a ...interface{})
func VerboseInfoBar ¶
func VerboseInfoBar(text string, a ...interface{})
func VerboseSuccess ¶
func VerboseSuccess(text string, a ...interface{})
func VerboseSuccessBar ¶
func VerboseSuccessBar(text string, a ...interface{})
func VerboseWarning ¶
func VerboseWarning(text string, a ...interface{})
func VerboseWarningBar ¶
func VerboseWarningBar(text string, a ...interface{})
func WaitAllSpinners ¶ added in v0.2.1
func WaitAllSpinners()
func WarningBar ¶
func WarningBar(text string, a ...interface{})
func WarningBarIcon ¶
func WarningBarIcon(text string, a ...interface{})
func WarningLine ¶
func WarningLine()
func WarningLineBottom ¶
func WarningLineBottom()
func WarningLineText ¶
func WarningLineText(text string, a ...interface{})
func WarningLineTextTop ¶
func WarningLineTextTop(text string, a ...interface{})
func WarningLineTop ¶
func WarningLineTop()
Types ¶
type TaskSpinner ¶ added in v0.2.1
type TaskSpinner struct {
Prefix string
State int
FinalMSG string
MSG string
Name string
Ch chan string
SpinStates []string
// contains filtered or unexported fields
}
func AddSpinner ¶ added in v0.2.1
func AddSpinner(name string) *TaskSpinner
func NewTaskSpinner ¶ added in v0.2.1
func NewTaskSpinner(name string) *TaskSpinner
func (*TaskSpinner) Fail ¶ added in v0.2.1
func (t *TaskSpinner) Fail()
Fail set the task to the failure state. This will also stop the spinner and close its channel.
func (*TaskSpinner) Success ¶ added in v0.2.1
func (t *TaskSpinner) Success()
Success set the task to the succesful state. This will also stop the spinner and close its channel.
Click to show internal directories.
Click to hide internal directories.
