Documentation
¶
Index ¶
- Variables
- func Fprint(w io.Writer, msg string)
- func HasColors(str string) bool
- func RmColors(str string) string
- func WordWrap(lineWidth uint, texts ...string) string
- type CLI
- func (cli CLI) Ask(query string, args ...interface{}) (string, error)
- func (cli CLI) Error(msg string)
- func (cli CLI) Errorf(format string, args ...interface{})
- func (cli CLI) Fask(w io.Writer, query string, args ...interface{}) (string, error)
- func (cli CLI) Info(msg string)
- func (cli CLI) Infof(format string, args ...interface{})
- func (cli CLI) PrefixedLogger(prefix string) *Logger
- func (cli CLI) Print(msg string)
- func (cli CLI) Printf(msg string, args ...interface{})
- func (cli CLI) Prompt(commands []PromptCmd) error
- func (cli CLI) Warn(msg string)
- func (cli CLI) Warnf(format string, args ...interface{})
- type ColWriter
- type Color
- func (c Color) Black(msg string) string
- func (c Color) Blue(msg string) string
- func (c Color) Code(attr ColorCode, args ...ColorCode) string
- func (c Color) ColorFail() string
- func (c Color) ColorNeutral() string
- func (c Color) ColorReset() string
- func (c Color) ColorSuccess() string
- func (c Color) ColorWarn() string
- func (c Color) Cyan(msg string) string
- func (c Color) Fail(msg string) string
- func (c Color) Green(msg string) string
- func (c Color) Magenta(msg string) string
- func (c Color) Neutral(msg string) string
- func (c Color) Red(msg string) string
- func (c Color) Success(msg string) string
- func (c Color) Warn(msg string) string
- func (c Color) White(msg string) string
- func (c Color) Yellow(msg string) string
- type ColorCode
- type Logger
- func (l *Logger) Error(msg string)
- func (l *Logger) Errorf(format string, args ...interface{})
- func (l *Logger) Fprint(w io.Writer, msg string)
- func (l *Logger) Info(msg string)
- func (l *Logger) Infof(format string, args ...interface{})
- func (l *Logger) Print(msg string)
- func (l *Logger) Warn(msg string)
- func (l *Logger) Warnf(format string, args ...interface{})
- type PromptCmd
- type Table
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrPromptCommandIsNotKnown = errors.New("prompt command is not known")
View Source
var Input io.Reader = os.Stdin
View Source
var NoColor bool
Functions ¶
Types ¶
type CLI ¶ added in v0.4.0
func (CLI) PrefixedLogger ¶ added in v0.4.0
type ColWriter ¶ added in v0.2.0
type Color ¶ added in v0.4.0
type Color struct {
Disabled bool
}
func (Color) ColorNeutral ¶ added in v0.4.0
func (Color) ColorReset ¶ added in v0.4.0
func (Color) ColorSuccess ¶ added in v0.4.0
Click to show internal directories.
Click to hide internal directories.