code: func (s *Store) exportPublicKey(ctx context.Context, r string) (string, error) {
  	filename := filepath.Join(keyDir, r)
  
  	// do not overwrite existing keys
  	if s.storage.Exists(ctx, filename) {
  		return "", nil
  	}
  
  	pk, err := s.crypto.ExportPublicKey(ctx, r)
  	if err != nil {
  		return "", errors.Wrapf(err, "failed to export public key")
  	}
  
  	// ECC keys are at least 700 byte, RSA should be a lot bigger
  	if len(pk) < 32 {
  		return "", errors.New("exported key too small")
  	}
  
  	if err := s.storage.Set(ctx, filename, pk); err != nil {
  		return "", errors.Wrapf(err, "failed to write exported public key to store")
  	}
  
  	return filename, nil
  }
docs: // export an ASCII armored public key