diff --git a/cmd/version.go b/cmd/version.go index 7e8cbe2a1..a4479752d 100644 --- a/cmd/version.go +++ b/cmd/version.go @@ -2,6 +2,7 @@ package cmd import ( "fmt" + "runtime/debug" "github.com/spf13/cobra" ) @@ -22,6 +23,11 @@ func NewVersionCommand() *cobra.Command { fmt.Printf("build date: %s\n", BuildDate) fmt.Printf("scm hash: %s\n", BuildHash) fmt.Printf("environment: %s\n", BuildEnvironment) + + bi, ok := debug.ReadBuildInfo() + if ok && bi != nil { + fmt.Printf("go version: %s\n", bi.GoVersion) + } }, }