code: func ShortenConfig(config *Config) {
  	// trick json encoder into printing a human readable string in the raw data
  	// by base64 decoding what we want to print. Relies on implementation of
  	// http://golang.org/pkg/encoding/json/#Marshal using base64 to encode []byte
  	for key, authInfo := range config.AuthInfos {
  		if len(authInfo.ClientKeyData) > 0 {
  			authInfo.ClientKeyData = redactedBytes
  		}
  		if len(authInfo.ClientCertificateData) > 0 {
  			authInfo.ClientCertificateData = redactedBytes
  		}
  		config.AuthInfos[key] = authInfo
  	}
  	for key, cluster := range config.Clusters {
  		if len(cluster.CertificateAuthorityData) > 0 {
  			cluster.CertificateAuthorityData = dataOmittedBytes
  		}
  		config.Clusters[key] = cluster
  	}
  }
docs: // Flatten redacts raw data entries from the config object for a human-readable view.