- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for GetRootCmd (0.17 sec)
-
istioctl/cmd/istioctl_test.go
// unknown flags should be a command parse rootCmd := GetRootCmd([]string{"--unknown-flag"}) fErr := rootCmd.Execute() switch fErr.(type) { case istioctlutil.CommandParseError: // do nothing default: t.Errorf("Expected a CommandParseError, but got %q.", fErr) } // we should propagate to subcommands rootCmd = GetRootCmd([]string{"analyze", "--unknown-flag"}) fErr = rootCmd.Execute()
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Tue Aug 29 14:53:25 UTC 2023 - 1.5K bytes - Viewed (0) -
istioctl/cmd/options_test.go
--log_target: The set of paths where to output the log. This can be any path as well as the special values stdout and stderr ` func TestLogHelp(t *testing.T) { var out bytes.Buffer rootCmd := GetRootCmd([]string{"options"}) rootCmd.SetOut(&out) rootCmd.SetErr(&out) fErr := rootCmd.Execute() if fErr != nil { t.Fatalf("options failed with %v and %q\n", fErr, out.String()) }
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Wed Sep 14 02:38:54 UTC 2022 - 1.9K bytes - Viewed (0) -
istioctl/cmd/istioctl/main.go
) func main() { if err := cmd.ConfigAndEnvProcessing(); err != nil { fmt.Fprintf(os.Stderr, "Could not initialize: %v\n", err) exitCode := cmd.GetExitCode(err) os.Exit(exitCode) } rootCmd := cmd.GetRootCmd(os.Args[1:]) log.EnableKlogWithCobra() if err := rootCmd.Execute(); err != nil { exitCode := cmd.GetExitCode(err) os.Exit(exitCode) }
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Tue May 23 17:08:31 UTC 2023 - 1.1K bytes - Viewed (0) -
istioctl/cmd/root.go
return err } return nil } func init() { viper.SetDefault("istioNamespace", constants.IstioSystemNamespace) viper.SetDefault("xds-port", 15012) } // GetRootCmd returns the root of the cobra command-tree. func GetRootCmd(args []string) *cobra.Command { rootCmd := &cobra.Command{ Use: "istioctl", Short: "Istio control interface.", SilenceUsage: true,
Registered: Wed Nov 06 22:53:10 UTC 2024 - Last Modified: Mon Aug 05 02:08:47 UTC 2024 - 9.6K bytes - Viewed (0)