From 0783ca3793f9b1bf1c6c1038bc34378b3a4b44ba Mon Sep 17 00:00:00 2001 From: John Date: Tue, 25 Oct 2022 00:17:48 +0800 Subject: [PATCH] cli: version to the $ coder header in CLI (#4709) --- cli/root.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cli/root.go b/cli/root.go index c40bd927e2..2682e164a4 100644 --- a/cli/root.go +++ b/cli/root.go @@ -108,12 +108,13 @@ func AGPL() []*cobra.Command { } func Root(subcommands []*cobra.Command) *cobra.Command { + fmtLong := `Coder %s — A tool for provisioning self-hosted development environments with Terraform. +` cmd := &cobra.Command{ Use: "coder", SilenceErrors: true, SilenceUsage: true, - Long: `Coder — A tool for provisioning self-hosted development environments with Terraform. -`, + Long: fmt.Sprintf(fmtLong, buildinfo.Version()), PersistentPreRun: func(cmd *cobra.Command, args []string) { if cliflag.IsSetBool(cmd, varNoVersionCheck) && cliflag.IsSetBool(cmd, varNoFeatureWarning) {