You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
logger.Error("here is the error") // stderr: 'ERROR: here is the error'
31
31
@@ -36,13 +36,13 @@ logger := logs.NewLogger().
36
36
AddTime(true).
37
37
AddDate(true)
38
38
39
-
logger.Warn("This is my Warn log", "Test arg") // stdout: WARN[03/11/2024 18:35:43]: This is my Warn log Test arg
39
+
logger.Warn("This is my Warn log") // stdout: WARN[03/11/2024 18:35:43]: This is my Warn log
40
40
41
41
logger.SetEncoder(shared.JsonEncoderType)
42
-
logger.Debug("This is my Debug log", "Test arg") // stdout: {"level":"DEBUG","date":"03/11/2024","time":"18:35:43","message":"This is my Debug log Test arg"}
42
+
logger.Debug("This is my Debug log") // stdout: {"level":"DEBUG","datetime":"03/11/202418:35:43","message":"This is my Debug log"}
43
43
44
44
logger.AddTime(false)
45
-
logger.Debug("This is my Debug log", "Test arg") // stdout: {"level":"DEBUG","date":"03/11/2024","message":"This is my Debug log Test second arg"}
45
+
logger.Debug("This is my Debug log") // stdout: {"level":"DEBUG","date":"03/11/2024","message":"This is my Debug log"}
46
46
47
47
/******************** Logging to a file example ********************/
0 commit comments