func GetConfigCmd() *cobra.Command {
	var cro = &cli.GetConfigOptions{}
	var getConfigCmd = &cobra.Command{
		Use:   "getconfig <NAME>",
		Short: "Manage Kubernetes configuration",
		Long: `Use this command to pull a kubeconfig file from a cluster so you can use kubectl.
	
	This command will attempt to find a cluster, and append a local kubeconfig file with a kubeconfig `,
		Run: func(cmd *cobra.Command, args []string) {
			switch len(args) {
			case 0:
				cro.Name = viper.GetString(keyKubicornName)
			case 1:
				cro.Name = args[0]
			default:
				logger.Critical("Too many arguments.")
				os.Exit(1)
			}

			if err := runGetConfig(cro); err != nil {
				logger.Critical(err.Error())
				os.Exit(1)
			}

		},
	}

	fs := getConfigCmd.Flags()

	bindCommonStateStoreFlags(&cro.StateStoreOptions, fs)
	bindCommonAwsFlags(&cro.AwsOptions, fs)

	fs.StringVar(&cro.GitRemote, keyGitConfig, viper.GetString(keyGitConfig), descGitConfig)

	return getConfigCmd
}
func GetConfigCmd() *cobra.Command {
	var cro = &cli.GetConfigOptions{}
	var getConfigCmd = &cobra.Command{
		Use:   "getconfig <NAME>",
		Short: "Manage Kubernetes configuration",
		Long: `Use this command to pull a kubeconfig file from a cluster so you can use kubectl.
	
	This command will attempt to find a cluster, and append a local kubeconfig file with a kubeconfig `,
		Run: func(cmd *cobra.Command, args []string) {
			switch len(args) {
			case 0:
				cro.Name = viper.GetString(keyKubicornName)
			case 1:
				cro.Name = args[0]
			default:
				logger.Critical("Too many arguments.")
				os.Exit(1)
			}

			if err := runGetConfig(cro); err != nil {
				logger.Critical(err.Error())
				os.Exit(1)
			}

		},
	}

	fs := getConfigCmd.Flags()

	bindCommonStateStoreFlags(&cro.StateStoreOptions, fs)
	bindCommonAwsFlags(&cro.AwsOptions, fs)

	fs.StringVar(&cro.GitRemote, keyGitConfig, viper.GetString(keyGitConfig), descGitConfig)

	return getConfigCmd
}
func GetConfigCmd ( ) * cobra . Command { var cro = & cli . GetConfigOptions { } var getConfigCmd = & cobra . Command { Use : " " , Short : " " , Long : `Use this command to pull a kubeconfig file from a cluster so you can use kubectl.
	
	This command will attempt to find a cluster, and append a local kubeconfig file with a kubeconfig ` , Run : func ( cmd * cobra . Command , args [ ] string ) { switch len ( args ) { case 0 : cro . Name = viper . GetString ( keyKubicornName ) case 1 : cro . Name = args [ 0 ] default : logger . Critical ( " " ) os . Exit ( 1 ) } if err := runGetConfig ( cro ) ; err != nil { logger . Critical ( err . Error ( ) ) os . Exit ( 1 ) } } , } fs := getConfigCmd . Flags ( ) bindCommonStateStoreFlags ( & cro . StateStoreOptions , fs ) bindCommonAwsFlags ( & cro . AwsOptions , fs ) fs . StringVar ( & cro . GitRemote , keyGitConfig , viper . GetString ( keyGitConfig ) , descGitConfig ) return getConfigCmd }
// GetConfigCmd represents the apply command
GetConfigCmd represents the apply command