code: func Validate(config clientcmdapi.Config) error {
  	validationErrors := make([]error, 0)
  
  	if clientcmdapi.IsConfigEmpty(&config) {
  		return newErrConfigurationInvalid([]error{ErrEmptyConfig})
  	}
  
  	if len(config.CurrentContext) != 0 {
  		if _, exists := config.Contexts[config.CurrentContext]; !exists {
  			validationErrors = append(validationErrors, &errContextNotFound{config.CurrentContext})
  		}
  	}
  
  	for contextName, context := range config.Contexts {
  		validationErrors = append(validationErrors, validateContext(contextName, *context, config)...)
  	}
  
  	for authInfoName, authInfo := range config.AuthInfos {
  		validationErrors = append(validationErrors, validateAuthInfo(authInfoName, *authInfo)...)
  	}
  
  	for clusterName, clusterInfo := range config.Clusters {
  		validationErrors = append(validationErrors, validateClusterInfo(clusterName, *clusterInfo)...)
  	}
  
  	return newErrConfigurationInvalid(validationErrors)
  }
docs: // Validate checks for errors in the Config.  It does not return early so that it can find as many errors as possible.