logger

package
v0.0.12 Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2022 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckAndPanic added in v0.0.3

func CheckAndPanic(err error)

func Debug

func Debug(f string, s ...any)

func Disable added in v0.0.3

func Disable()

func Err

func Err(err error)

func IsDebug

func IsDebug() bool

func ReadAllLogContent

func ReadAllLogContent() (logMap sync.Map)

读取所有日志 return map(k: 文件名 v: 文件内容) todo: 根据投票情况考虑时候添加日志上传功能

func Setup added in v0.0.3

func Setup(actions ...SettingsAction) error

func ShowGuiMsg added in v0.0.2

func ShowGuiMsg(title, message string)

func Var

func Var(f string, s ...any)

Types

type Settings added in v0.0.3

type Settings struct {
	*sync.RWMutex
	// contains filtered or unexported fields
}

type SettingsAction added in v0.0.3

type SettingsAction func(set *Settings) error

func SetDebugMode added in v0.0.3

func SetDebugMode(isDebugMode bool) SettingsAction

func SetMuteMode added in v0.0.3

func SetMuteMode(isEnabledMute bool) SettingsAction

仅必要输出 var/err

func SetOutput added in v0.0.3

func SetOutput(path string, isOneFile bool) SettingsAction

Jump to

Keyboard shortcuts

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