mirror of
https://github.com/mikefarah/yq.git
synced 2024-11-12 05:38:04 +00:00
Improved log format
This commit is contained in:
parent
d9e1a789ea
commit
9142c93d1b
@ -41,7 +41,7 @@ yq -P -oy sample.json
|
||||
cmd.SetOut(cmd.OutOrStdout())
|
||||
|
||||
var format = logging.MustStringFormatter(
|
||||
`%{color}%{time:15:04:05} %{shortfunc} [%{level:.4s}]%{color:reset} %{message}`,
|
||||
`[%{level:5.5s}] %{color}%{time:15:04:05} %{color:bold} %{shortfile:-30s} %{shortfunc:-25s}%{color:reset} %{message}`,
|
||||
)
|
||||
var backend = logging.AddModuleLevel(
|
||||
logging.NewBackendFormatter(logging.NewLogBackend(os.Stderr, "", 0), format))
|
||||
|
@ -252,3 +252,4 @@ zabbix
|
||||
tonumber
|
||||
noyaml
|
||||
nolint
|
||||
shortfile
|
Loading…
Reference in New Issue
Block a user