Class: Xshellz::CommandResult
- Inherits:
-
Struct
- Object
- Struct
- Xshellz::CommandResult
- Defined in:
- lib/xshellz/models.rb
Overview
The outcome of a single Sandbox#run invocation.
A non-zero exit_code does NOT raise - it is data, exactly like a local
subprocess call.
Instance Attribute Summary collapse
-
#exit_code ⇒ Object
Returns the value of attribute exit_code.
-
#stderr ⇒ Object
Returns the value of attribute stderr.
-
#stdout ⇒ Object
Returns the value of attribute stdout.
Instance Method Summary collapse
-
#ok? ⇒ Boolean
True when the command exited with status 0.
Instance Attribute Details
#exit_code ⇒ Object
Returns the value of attribute exit_code
8 9 10 |
# File 'lib/xshellz/models.rb', line 8 def exit_code @exit_code end |
#stderr ⇒ Object
Returns the value of attribute stderr
8 9 10 |
# File 'lib/xshellz/models.rb', line 8 def stderr @stderr end |
#stdout ⇒ Object
Returns the value of attribute stdout
8 9 10 |
# File 'lib/xshellz/models.rb', line 8 def stdout @stdout end |
Instance Method Details
#ok? ⇒ Boolean
True when the command exited with status 0.
10 11 12 |
# File 'lib/xshellz/models.rb', line 10 def ok? exit_code == 0 end |