From 9bc179032057289ba3af254af65b6524e1ef1c8a Mon Sep 17 00:00:00 2001 From: Anton Kaliaev Date: Wed, 24 May 2017 14:28:25 +0200 Subject: [PATCH] tracing logger (Refs #506) DEPENDS ON https://github.com/tendermint/tmlibs/pull/21 --- cmd/tendermint/commands/root.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cmd/tendermint/commands/root.go b/cmd/tendermint/commands/root.go index 3565f3bb8..d0c5f90eb 100644 --- a/cmd/tendermint/commands/root.go +++ b/cmd/tendermint/commands/root.go @@ -8,6 +8,7 @@ import ( tmflags "github.com/tendermint/tendermint/cmd/tendermint/commands/flags" cfg "github.com/tendermint/tendermint/config" + "github.com/tendermint/tmlibs/cli" "github.com/tendermint/tmlibs/log" ) @@ -34,6 +35,9 @@ var RootCmd = &cobra.Command{ if err != nil { return err } + if viper.GetBool(cli.TraceFlag) { + logger = log.NewTracingLogger(logger) + } return nil }, }