Skip to content

Instantly share code, notes, and snippets.

@studio3104
Created November 26, 2012 08:41
Show Gist options
  • Save studio3104/4147232 to your computer and use it in GitHub Desktop.
Save studio3104/4147232 to your computer and use it in GitHub Desktop.
Yield?
# Yields once for each key pair in your account.
# @return [nil]
def each &block
response = filtered_request(:describe_key_pairs)
response.key_set.each do |kp|
yield(KeyPair.new(kp.key_name,
:fingerprint => kp.key_fingerprint,
:config => config))
end
nil
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment