Class: Dctl::Command::RedirectibleCommand
- Inherits:
-
SmartCommand
- Object
- CommandParser::Command
- SmartCommand
- Dctl::Command::RedirectibleCommand
- Defined in:
- lib/dctl/command.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize ⇒ RedirectibleCommand
constructor
A new instance of RedirectibleCommand.
Constructor Details
#initialize ⇒ RedirectibleCommand
Returns a new instance of RedirectibleCommand.
24 25 26 27 28 29 30 31 32 33 |
# File 'lib/dctl/command.rb', line 24 def initialize super @stdin = $IN @stdout = $OUT @stderr = $ERR .separator "Options:" .on('-i', '--stdin FILE', "Use FILE as stdin when daemonized (default is '#{@stdin}').") { |@stdin| } .on('-o', '--stdout FILE', "Use FILE as stdout when daemonized (default is '#{@stdout}').") { |@stdout| } .on('-e', '--stderr FILE', "Use FILE as stderr when daemonized (default is '#{@stderr}').") { |@stderr| } end |