Exception: MGit::SystemCommandError
- Inherits:
-
StandardError
- Object
- StandardError
- MGit::SystemCommandError
- Defined in:
- lib/mgit/exceptions.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#cmd ⇒ Object
readonly
Returns the value of attribute cmd.
-
#error ⇒ Object
readonly
Returns the value of attribute error.
Instance Method Summary collapse
-
#initialize(cmd, error) ⇒ SystemCommandError
constructor
A new instance of SystemCommandError.
- #to_s ⇒ Object
Constructor Details
#initialize(cmd, error) ⇒ SystemCommandError
Returns a new instance of SystemCommandError.
7 8 9 10 |
# File 'lib/mgit/exceptions.rb', line 7 def initialize(cmd, error) @cmd = cmd @error = error end |
Instance Attribute Details
#cmd ⇒ Object (readonly)
Returns the value of attribute cmd.
5 6 7 |
# File 'lib/mgit/exceptions.rb', line 5 def cmd @cmd end |
#error ⇒ Object (readonly)
Returns the value of attribute error.
5 6 7 |
# File 'lib/mgit/exceptions.rb', line 5 def error @error end |
Instance Method Details
#to_s ⇒ Object
12 13 14 |
# File 'lib/mgit/exceptions.rb', line 12 def to_s "Error: #{@error}\nCommand was: #{@cmd}" end |