lib/tailog/ext/irb.rb in tailog-0.5.4 vs lib/tailog/ext/irb.rb in tailog-0.5.5
- old
+ new
@@ -1,8 +1,10 @@
require 'irb'
IRB.setup nil
+IRB.conf[:PROMPT_MODE] = :DEFAULT
+IRB.conf[:VERBOSE] = false
def IRB.Output
IRB.conf[:OUTPUT]
end
@@ -36,14 +38,14 @@
context = IRB.CurrentContext
IRB.Output << [ :stdout, context.return_format % context.inspect_last_value ]
end
def print *args
- IRB.Output << [ :stderr, args.join ]
+ IRB.Output << [ :stderr, args.join, caller ]
end
def printf format, *args
- IRB.Output << [ :stderr, format % args ]
+ IRB.Output << [ :stderr, format % args, caller ]
end
end
class StringInputMethod < StringIO
attr_accessor :prompt