From d373b98318e1123bba11418fd847f40a30019baf Mon Sep 17 00:00:00 2001 From: Vibhav Bobade Date: Mon, 2 Sep 2019 16:35:06 +0530 Subject: [PATCH] Update debug to have timestamps Signed-off-by: Vibhav Bobade --- cmd/helm/helm.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmd/helm/helm.go b/cmd/helm/helm.go index cdacf0b0c..5140c40b9 100644 --- a/cmd/helm/helm.go +++ b/cmd/helm/helm.go @@ -23,6 +23,7 @@ import ( "os" "strings" "sync" + "time" "github.com/spf13/cobra" "github.com/spf13/pflag" @@ -55,7 +56,8 @@ func init() { func debug(format string, v ...interface{}) { if settings.Debug { - format = fmt.Sprintf("[debug] %s\n", format) + timeNow := time.Now().UTC().String() + format = fmt.Sprintf("%s [debug] %s\n", timeNow, format) log.Output(2, fmt.Sprintf(format, v...)) } }