1 Star 0 Fork 0

白菜林 / go-log

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
color.go 483 Bytes
一键复制 编辑 原始数据 按行查看 历史
白菜林 提交于 2019-08-04 18:30 . go log
package color
import (
"fmt"
)
const (
//Black is a constant of type int
Black = iota + 30
Red
Green
Yellow
Blue
Magenta
Cyan
White
)
var (
//InfoByte is a variable of type []byte
DebugByte = []byte(fmt.Sprintf("\x1b[0;%dm%s\x1b[0m", Blue, "DEBUG"))
WarnByte = []byte(fmt.Sprintf("\x1b[0;%dm%s\x1b[0m", Yellow, "WARN"))
ErrorByte = []byte(fmt.Sprintf("\x1b[0;%dm%s\x1b[0m", Red, "ERROR"))
FatalByte = []byte(fmt.Sprintf("\x1b[0;%dm%s\x1b[0m", Magenta, "FATAL"))
)
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/lyhuilin/log.git
git@gitee.com:lyhuilin/log.git
lyhuilin
log
go-log
v0.0.1

搜索帮助