Class: Smith::Commands::Group
- Inherits:
-
Smith::CommandBase
- Object
- Smith::CommandBase
- Smith::Commands::Group
- Includes:
- Common
- Defined in:
- lib/smith/commands/agency/group.rb
Instance Attribute Summary
Attributes inherited from Smith::CommandBase
Instance Method Summary collapse
- #execute ⇒ Object
-
#group(&blk) ⇒ Object
Returns the agents in a group.
- #options_spec ⇒ Object
Methods included from Common
Methods inherited from Smith::CommandBase
#banner, #format_help, #initialize, #parse_options
Methods included from Logger
Constructor Details
This class inherits a constructor from Smith::CommandBase
Instance Method Details
#execute ⇒ Object
9 10 11 12 13 |
# File 'lib/smith/commands/agency/group.rb', line 9 def execute group do |value| responder.succeed(value) end end |
#group(&blk) ⇒ Object
Returns the agents in a group.
16 17 18 19 20 21 22 |
# File 'lib/smith/commands/agency/group.rb', line 16 def group(&blk) begin blk.call(agent_group(target.first).join(' ')) rescue RuntimeError => e blk.call(e.) end end |
#options_spec ⇒ Object
24 25 26 |
# File 'lib/smith/commands/agency/group.rb', line 24 def "Lists the agents in a group." end |