logger

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2020 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Logger

func Logger() *zap.SugaredLogger

func SetupLogger

func SetupLogger(verbose bool) error

SetupLogger sets up the global logger to be used in all the cli, configuring the logging level to debug whenever verbose is true, and info otherwise. This function will act as a no-op after the first time it is called. Returns an error in case could not be built from the configuration

Types

type GenericLogger

type GenericLogger interface {
	Warn(args ...interface{})
	Warnf(template string, args ...interface{})
	Info(args ...interface{})
	Infof(template string, args ...interface{})
	Debug(args ...interface{})
	Debugf(template string, args ...interface{})
	Error(args ...interface{})
	Errorf(template string, args ...interface{})
	Fatal(args ...interface{})
	Fatalf(template string, args ...interface{})
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL