Exception: Mimas::SSH::Session::NonZeroExitCode
- Inherits:
-
StandardError
- Object
- StandardError
- Mimas::SSH::Session::NonZeroExitCode
- Defined in:
- lib/mimas/ssh/session.rb
Instance Attribute Summary collapse
-
#exit_code ⇒ Object
readonly
Returns the value of attribute exit_code.
-
#output ⇒ Object
readonly
Returns the value of attribute output.
Instance Method Summary collapse
-
#initialize(command:, exit_code:, output:) ⇒ NonZeroExitCode
constructor
A new instance of NonZeroExitCode.
- #to_s ⇒ Object
Constructor Details
#initialize(command:, exit_code:, output:) ⇒ NonZeroExitCode
Returns a new instance of NonZeroExitCode.
6 7 8 9 10 |
# File 'lib/mimas/ssh/session.rb', line 6 def initialize(command:, exit_code:, output:) @command = command @exit_code = exit_code @output = output end |
Instance Attribute Details
#exit_code ⇒ Object (readonly)
Returns the value of attribute exit_code.
5 6 7 |
# File 'lib/mimas/ssh/session.rb', line 5 def exit_code @exit_code end |
#output ⇒ Object (readonly)
Returns the value of attribute output.
5 6 7 |
# File 'lib/mimas/ssh/session.rb', line 5 def output @output end |
Instance Method Details
#to_s ⇒ Object
12 13 14 |
# File 'lib/mimas/ssh/session.rb', line 12 def to_s "'#{@command}' exited with code: #{@exit_code}" end |