Documentation
¶
Index ¶
- Constants
- Variables
- func ApplySettings(enableTags, disableTags string, enable, disable interface{})
- func Bold(s string) string
- func Builder(level Level, prefix string) builder
- func Colorized() bool
- func Colors() int
- func Cyan(s string) string
- func Debug(args ...interface{})
- func Debugf(format string, args ...interface{})
- func Error(args ...interface{})
- func Errorf(format string, args ...interface{})
- func Execution(name string, err error, out io.Reader)
- func Failure(indent int, name, failText string, duration time.Duration)
- func Gray(s string) string
- func Green(s string) string
- func Info(args ...interface{})
- func InfoPad(s string)
- func Infof(format string, args ...interface{})
- func InitSettings()
- func LogMeta(hookName string)
- func Printf(format string, args ...interface{})
- func Println(args ...interface{})
- func Red(s string) string
- func Separate(s string)
- func SetColors(colors interface{})
- func SetLevel(level Level)
- func SetName(name string)
- func SetOutput(out io.Writer)
- func Skip(name, reason string)
- func StartSpinner()
- func StopSpinner()
- func Success(indent int, name string, duration time.Duration)
- func UnsetName(name string)
- func Warn(args ...interface{})
- func Warnf(format string, args ...interface{})
- func Yellow(s string) string
- type Level
- type LogSettings
- func (s *LogSettings) Apply(enableTags, disableTags string, enable, disable interface{})
- func (s LogSettings) LogEmptySummary() bool
- func (s LogSettings) LogExecution() bool
- func (s LogSettings) LogExecutionInfo() bool
- func (s LogSettings) LogExecutionOutput() bool
- func (s LogSettings) LogFailure() bool
- func (s LogSettings) LogMeta() bool
- func (s LogSettings) LogSkips() bool
- func (s LogSettings) LogSuccess() bool
- func (s LogSettings) LogSummary() bool
- type Logger
- func (l *Logger) Debug(args ...string)
- func (l *Logger) Debugf(format string, args ...interface{})
- func (l *Logger) Error(args ...string)
- func (l *Logger) Errorf(format string, args ...interface{})
- func (l *Logger) Info(args ...interface{})
- func (l *Logger) Infof(format string, args ...interface{})
- func (l *Logger) IsLevelEnabled(level Level) bool
- func (l *Logger) Log(level Level, args ...interface{})
- func (l *Logger) Logf(level Level, format string, args ...interface{})
- func (l *Logger) Printf(format string, args ...interface{})
- func (l *Logger) Println(args ...interface{})
- func (l *Logger) SetLevel(level Level)
- func (l *Logger) SetName(name string)
- func (l *Logger) SetOutput(out io.Writer)
- func (l *Logger) UnsetName(name string)
- func (l *Logger) Warn(args ...string)
- func (l *Logger) Warnf(format string, args ...interface{})
- type StyleLogger
Constants ¶
View Source
const ( ErrorLevel Level = iota WarnLevel InfoLevel DebugLevel ColorAuto = iota ColorOn ColorOff )
Variables ¶
View Source
var ( ColorRed lipgloss.TerminalColor = lipgloss.CompleteColor{TrueColor: "#ff6347", ANSI256: "196", ANSI: "9"} ColorGreen lipgloss.TerminalColor = lipgloss.CompleteColor{TrueColor: "#32cd32", ANSI256: "148", ANSI: "2"} ColorYellow lipgloss.TerminalColor = lipgloss.CompleteColor{TrueColor: "#fada5e", ANSI256: "191", ANSI: "11"} ColorCyan lipgloss.TerminalColor = lipgloss.CompleteColor{TrueColor: "#70C0BA", ANSI256: "37", ANSI: "14"} GolorGray lipgloss.TerminalColor = lipgloss.CompleteColor{TrueColor: "#808080", ANSI256: "244", ANSI: "7"} )
Functions ¶
func ApplySettings ¶ added in v1.13.0
func ApplySettings(enableTags, disableTags string, enable, disable interface{})
func InitSettings ¶ added in v1.13.0
func InitSettings()
func StartSpinner ¶
func StartSpinner()
func StopSpinner ¶
func StopSpinner()
Types ¶
type LogSettings ¶ added in v1.6.6
type LogSettings struct {
// contains filtered or unexported fields
}
var Settings LogSettings
func NewSettings ¶ added in v1.6.6
func NewSettings() LogSettings
func (*LogSettings) Apply ¶ added in v1.6.6
func (s *LogSettings) Apply(enableTags, disableTags string, enable, disable interface{})
func (LogSettings) LogEmptySummary ¶ added in v1.6.6
func (s LogSettings) LogEmptySummary() bool
func (LogSettings) LogExecution ¶ added in v1.6.6
func (s LogSettings) LogExecution() bool
func (LogSettings) LogExecutionInfo ¶ added in v1.6.6
func (s LogSettings) LogExecutionInfo() bool
func (LogSettings) LogExecutionOutput ¶ added in v1.6.6
func (s LogSettings) LogExecutionOutput() bool
func (LogSettings) LogFailure ¶ added in v1.6.6
func (s LogSettings) LogFailure() bool
func (LogSettings) LogMeta ¶ added in v1.6.6
func (s LogSettings) LogMeta() bool
func (LogSettings) LogSkips ¶ added in v1.6.6
func (s LogSettings) LogSkips() bool
func (LogSettings) LogSuccess ¶ added in v1.6.6
func (s LogSettings) LogSuccess() bool
func (LogSettings) LogSummary ¶ added in v1.6.6
func (s LogSettings) LogSummary() bool
type Logger ¶
type Logger struct {
// contains filtered or unexported fields
}
func (*Logger) IsLevelEnabled ¶
type StyleLogger ¶ added in v1.5.0
type StyleLogger struct {
// contains filtered or unexported fields
}
func Styled ¶ added in v1.5.0
func Styled() StyleLogger
func (StyleLogger) Info ¶ added in v1.5.0
func (s StyleLogger) Info(str string)
func (StyleLogger) WithLeftBorder ¶ added in v1.5.0
func (s StyleLogger) WithLeftBorder(border lipgloss.Border, color lipgloss.TerminalColor) StyleLogger
func (StyleLogger) WithPadding ¶ added in v1.5.0
func (s StyleLogger) WithPadding(m int) StyleLogger
Click to show internal directories.
Click to hide internal directories.