code: func KeyIdFromRing(secRing string) (keyID string, err error) {
  	f, err := wkfs.Open(secRing)
  	if err != nil {
  		return "", fmt.Errorf("Could not open secret ring file %v: %v", secRing, err)
  	}
  	defer f.Close()
  	el, err := openpgp.ReadKeyRing(f)
  	if err != nil {
  		return "", fmt.Errorf("Could not read secret ring file %s: %v", secRing, err)
  	}
  	if len(el) != 1 {
  		return "", fmt.Errorf("Secret ring file %v contained %d identities; expected 1", secRing, len(el))
  	}
  	ent := el[0]
  	return ent.PrimaryKey.KeyIdString(), nil
  }
docs: // KeyIdFromRing returns the public keyID contained in the secret
  // ring file secRing. It expects only one keyID in this secret ring
  // and returns an error otherwise.