logfactory

package
v0.0.0-...-66224dc Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewColorfulLogger

func NewColorfulLogger() *logrus.Logger

创建一个 带颜色的控制台日志对象

func NewFileLogger

func NewFileLogger(filePath string) *logrus.Logger

创建一个 文件日志对象, 不带颜色

Types

type CustomLogFormatter

type CustomLogFormatter struct {
	logrus.Formatter
}

Custom log format definition

自定义日志格式化

func (*CustomLogFormatter) Format

func (s *CustomLogFormatter) Format(entry *logrus.Entry) ([]byte, error)

Jump to

Keyboard shortcuts

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