1
0
mirror of synced 2026-02-06 19:05:55 +00:00

Add -n shorthand for namespace flag

This commit is contained in:
stefanprodan
2020-09-16 14:07:02 +03:00
parent 0b14328024
commit fafcf09570
50 changed files with 52 additions and 55 deletions

View File

@@ -117,12 +117,9 @@ var (
)
func init() {
rootCmd.PersistentFlags().StringVar(&namespace, "namespace", defaultNamespace,
"the namespace scope for this operation")
rootCmd.PersistentFlags().DurationVarP(&timeout, "timeout", "", 5*time.Minute,
"timeout for this operation")
rootCmd.PersistentFlags().BoolVarP(&verbose, "verbose", "", false,
"print generated objects")
rootCmd.PersistentFlags().StringVarP(&namespace, "namespace", "n", defaultNamespace, "the namespace scope for this operation")
rootCmd.PersistentFlags().DurationVar(&timeout, "timeout", 5*time.Minute, "timeout for this operation")
rootCmd.PersistentFlags().BoolVar(&verbose, "verbose", false, "print generated objects")
}
func main() {