From a74b1c815fe8cd390b1339a80e7ab10d8dbbef7f Mon Sep 17 00:00:00 2001 From: satoru Date: Fri, 15 Mar 2024 11:10:10 +0800 Subject: [PATCH] Remove deprecated call This is no longer necessary after Go 1.20 --- cmd/krew/cmd/root.go | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/cmd/krew/cmd/root.go b/cmd/krew/cmd/root.go index bfc9f8e9..857aa7b4 100644 --- a/cmd/krew/cmd/root.go +++ b/cmd/krew/cmd/root.go @@ -17,17 +17,15 @@ package cmd import ( "flag" "fmt" - "math/rand" - "os" - "strings" - "time" - "github.com/fatih/color" "github.com/mattn/go-isatty" "github.com/pkg/errors" "github.com/spf13/cobra" "github.com/spf13/pflag" "k8s.io/klog/v2" + "math/rand" + "os" + "strings" "sigs.k8s.io/krew/cmd/krew/cmd/internal" "sigs.k8s.io/krew/internal/environment" @@ -87,7 +85,6 @@ func Execute() { func init() { klog.InitFlags(nil) - rand.Seed(time.Now().UnixNano()) pflag.CommandLine.AddGoFlagSet(flag.CommandLine) _ = flag.CommandLine.Parse([]string{}) // convince pkg/flag we parsed the flags