Harbor Documentation

Harbor::Console

Heplful to include in your config.ru for getting an interative IRB session.

   #!/usr/bin/env ruby
   # require app, set up ORM, etc.

   if $0 == __FILE__
     Harbor::Console.start
   else
     run MyApplication
   end

Parent

Methods

Public Class Methods

start()

      # File lib/harbor/console.rb, line 17
17:     def self.start
18:       require 'irb'
19: 
20:       begin
21:         require 'irb/completion'
22:       rescue Exception
23:         # No readline available, proceed anyway.
24:       end
25: 
26:       if ::File.exists? ".irbrc"
27:         ENV['IRBRC'] = ".irbrc"
28:       end
29: 
30:       IRB.start
31:     end