Class: Ec2list::Command
- Inherits:
-
Object
- Object
- Ec2list::Command
- Defined in:
- lib/ec2list/command.rb
Instance Attribute Summary collapse
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(argv = []) ⇒ Command
constructor
A new instance of Command.
- #run ⇒ Object
Constructor Details
#initialize(argv = []) ⇒ Command
Returns a new instance of Command.
5 6 7 8 |
# File 'lib/ec2list/command.rb', line 5 def initialize(argv = []) @options = (argv) load_profile end |
Instance Attribute Details
#options ⇒ Object (readonly)
Returns the value of attribute options.
3 4 5 |
# File 'lib/ec2list/command.rb', line 3 def @options end |
Instance Method Details
#run ⇒ Object
10 11 12 13 14 15 16 |
# File 'lib/ec2list/command.rb', line 10 def run AWS.memoize do fetch_instances.each do |instance| print_instance(instance) end end end |