fix issues

This commit is contained in:
rogeecn
2023-08-04 18:45:46 +08:00
parent 4792452e1a
commit 3f0e648385
2 changed files with 14 additions and 2 deletions

View File

@@ -65,7 +65,17 @@ func LoadProviders(cfgFile, appName string, providers container.Providers) error
type Option func(*cobra.Command)
var AppName string
var (
AppName string
AppVersion string
)
func Version(ver string) Option {
return func(cmd *cobra.Command) {
cmd.Version = ver
AppVersion = ver
}
}
func Name(name string) Option {
return func(cmd *cobra.Command) {