logx

package
v0.0.0-...-3d3caa2 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const FileSuffix = ".log"
View Source
const LogPath = "./logs"

Variables

This section is empty.

Functions

func Blue

func Blue(str string) string

func Blue2Msg

func Blue2Msg(str string) string

func BlueMsg

func BlueMsg(str string) string

func Cyan

func Cyan(str string) string

func DebugMsg

func DebugMsg(str string) string

func Gray

func Gray(str string) string

func Green

func Green(str string) string

func Init

func Init()

func Magenta

func Magenta(str string) string

func Red

func Red(str string) string

func RedMsg

func RedMsg(str string) string

func TraceMsg

func TraceMsg(str string) string

func White

func White(str string) string

func Yellow

func Yellow(str string) string

func YellowMsg

func YellowMsg(str string) string

Types

type MyFormatter

type MyFormatter struct {
	IsColor  bool
	FullPath bool
}

MyFormatter 自定义的日志格式化器

func (*MyFormatter) Format

func (m *MyFormatter) Format(entry *logrus.Entry) ([]byte, error)

Jump to

Keyboard shortcuts

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