Method: MotherBrain.require_or_exit
- Defined in:
- lib/motherbrain.rb
.require_or_exit(library, message = nil) ⇒ Object
148 149 150 151 152 153 154 155 156 157 |
# File 'lib/motherbrain.rb', line 148 def require_or_exit(library, = nil) begin require library rescue LoadError ||= "#{library} was not found. Please add it to your Gemfile, " + "and then run `bundle install`." raise PrerequisiteNotInstalled, end end |