Sha256: 40c8e6bcd597c518a6e3e21ccc1279801d116d72a4037fb75e3cb1afd6fa6a07
Contents?: true
Size: 556 Bytes
Versions: 1
Compression:
Stored size: 556 Bytes
Contents
#from http://errtheblog.com/posts/9-drop-to-irb # call with IRB.start_session(Kernel.binding) in script require 'irb' module IRB def self.start_session(binding) IRB.setup(nil) workspace = WorkSpace.new(binding) if @CONF[:SCRIPT] irb = Irb.new(workspace, @CONF[:SCRIPT]) else irb = Irb.new(workspace) end @CONF[:IRB_RC].call(irb.context) if @CONF[:IRB_RC] @CONF[:MAIN_CONTEXT] = irb.context trap("SIGINT") do irb.signal_handle end catch(:IRB_EXIT) do irb.eval_input end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
cldwalker-core-0.0.0 | lib/core/irb.rb |