Documentation
¶
Overview ¶
Package nanolog implements a lightweight logger, featuring: - severity given by API, ie Infof(), Debugf() and related - automatic detection of interactive (terminal) or uninteractive (daemon) use - appropriate colour prefix for interactive output - appropriate syslog prefix for non-interactive output
Index ¶
- Constants
- Variables
- func Debug(format string, args ...any)
- func Error(format string, args ...any)
- func Fatal(format string, args ...any)
- func Filter(filter int)
- func Info(format string, args ...any)
- func NamedFilter(filter string) error
- func Warn(format string, args ...any)
- type Logger
- func (ml *Logger) Debug(format string, args ...any)
- func (ml *Logger) Error(format string, args ...any)
- func (ml *Logger) Fatal(format string, args ...any)
- func (ml *Logger) Filter(filter int)
- func (ml *Logger) Info(format string, args ...any)
- func (ml *Logger) NamedFilter(filter string) error
- func (ml *Logger) Warn(format string, args ...any)
Constants ¶
View Source
const ( LevelError = 4 LevelWarn = 5 LevelInfo = 6 LevelDebug = 7 )
Variables ¶
View Source
var (
Default, _ = New("", 0)
)
Functions ¶
func NamedFilter ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.