Exception: GLI::CustomExit
- Inherits:
-
StandardError
- Object
- StandardError
- GLI::CustomExit
- Includes:
- StandardException
- Defined in:
- lib/gli/exceptions.rb
Overview
Instance Attribute Summary collapse
-
#exit_code ⇒ Object
readonly
:nodoc:.
Instance Method Summary collapse
-
#initialize(message, exit_code) ⇒ CustomExit
constructor
Create a custom exit exception.
Constructor Details
#initialize(message, exit_code) ⇒ CustomExit
Create a custom exit exception
message
-
String containing error message to show the user
exit_code
-
the exit code to use (as an Int), overridding GLI’s default
117 118 119 120 |
# File 'lib/gli/exceptions.rb', line 117 def initialize(,exit_code) super() @exit_code = exit_code end |
Instance Attribute Details
#exit_code ⇒ Object (readonly)
:nodoc:
112 113 114 |
# File 'lib/gli/exceptions.rb', line 112 def exit_code @exit_code end |