mirror of
https://github.com/mikefarah/yq.git
synced 2025-01-24 14:45:39 +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))
|
||||
|
@ -251,4 +251,5 @@ yuin
|
||||
zabbix
|
||||
tonumber
|
||||
noyaml
|
||||
nolint
|
||||
nolint
|
||||
shortfile
|
Loading…
Reference in New Issue
Block a user