Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

Commit

Permalink
Merge pull request #2 from tarosky/dev/harai
Browse files Browse the repository at this point in the history
Change logging format
  • Loading branch information
harai authored Oct 1, 2020
2 parents d610986 + c9367ca commit f480f70
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion nudge.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,13 @@ import (
"github.com/tarosky/gutenberg-notifier/notify"
"github.com/urfave/cli/v2"
"go.uber.org/zap"
"go.uber.org/zap/zapcore"
)

func createLogger() *zap.Logger {
log, err := zap.NewDevelopment(zap.WithCaller(false))
cfg := zap.NewDevelopmentConfig()
cfg.EncoderConfig.EncodeTime = zapcore.TimeEncoderOfLayout("2006-01-02T15:04:05.000000Z0700")
log, err := cfg.Build(zap.WithCaller(false))
if err != nil {
panic("failed to initialize logger")
}
Expand Down

0 comments on commit f480f70

Please sign in to comment.