()
| 84 | } |
| 85 | |
| 86 | func initRootCmd() { |
| 87 | cobra.OnInitialize(initConfig) |
| 88 | apiKey = os.Getenv("PERFOPS_API_KEY") |
| 89 | |
| 90 | rootCmd.PersistentFlags().StringVarP(&apiKey, "key", "K", "", "The PerfOps API key (default is $PERFOPS_API_KEY)") |
| 91 | rootCmd.PersistentFlags().BoolVarP(&showVersion, "version", "v", false, "Prints the version information of perfops") |
| 92 | rootCmd.PersistentFlags().BoolVarP(&debug, "debug", "", false, "Enables debug output") |
| 93 | } |
| 94 | |
| 95 | // Common Flags for almost all tests we have |
| 96 | func addCommonFlags(cmd *cobra.Command) { |
no outgoing calls