mirror of
https://github.com/Threnklyn/jira.git
synced 2026-05-18 20:23:28 +02:00
change the default log output format
This commit is contained in:
+7
-1
@@ -21,7 +21,13 @@ import (
|
|||||||
|
|
||||||
var (
|
var (
|
||||||
log = logging.MustGetLogger("jira")
|
log = logging.MustGetLogger("jira")
|
||||||
defaultFormat = "%{color}%{time:2006-01-02T15:04:05.000Z07:00} %{level:-5s} [%{shortfile}]%{color:reset} %{message}"
|
defaultFormat = func() string {
|
||||||
|
format := os.Getenv("JIRA_LOG_FORMAT")
|
||||||
|
if format != "" {
|
||||||
|
return format
|
||||||
|
}
|
||||||
|
return "%{color}%{level:-5s}%{color:reset} %{message}"
|
||||||
|
}()
|
||||||
)
|
)
|
||||||
|
|
||||||
func handleExit() {
|
func handleExit() {
|
||||||
|
|||||||
Reference in New Issue
Block a user