github.com/authzed/spicedb@v1.32.1-0.20240520085336-ebda56537386/pkg/cmd/version.go (about) 1 package cmd 2 3 import ( 4 "github.com/jzelinskie/cobrautil/v2" 5 "github.com/spf13/cobra" 6 ) 7 8 func RegisterVersionFlags(cmd *cobra.Command) { 9 cobrautil.RegisterVersionFlags(cmd.Flags()) 10 } 11 12 func NewVersionCommand(programName string) *cobra.Command { 13 return &cobra.Command{ 14 Use: "version", 15 Short: "displays the version of SpiceDB", 16 RunE: cobrautil.VersionRunFunc(programName), 17 } 18 }