Class: Balmora::Context::Exec
- Inherits:
-
Balmora::Context
- Object
- Balmora::Command
- Balmora::Context
- Balmora::Context::Exec
- Defined in:
- lib/balmora/context/exec.rb
Direct Known Subclasses
Instance Method Summary collapse
Methods inherited from Balmora::Context
#_not, #execute, #init, #initialize, #option
Methods inherited from Balmora::Command
#_execute, #execute, #init, #initialize, #option
Constructor Details
This class inherits a constructor from Balmora::Context
Instance Method Details
#_exec ⇒ Object
19 20 21 22 23 24 |
# File 'lib/balmora/context/exec.rb', line 19 def _exec() exec = option(:exec) if exec.instance_of?(::String) exec = [@shell.expression(exec)] end end |
#options ⇒ Object
3 4 5 |
# File 'lib/balmora/context/exec.rb', line 3 def () return super().concat([:exec]) end |
#run ⇒ Object
15 16 17 |
# File 'lib/balmora/context/exec.rb', line 15 def run() return @shell.run!(_exec(), verbose: false).rstrip() end |