From: merch-redmine@... Date: 2019-08-07T15:37:18+00:00 Subject: [ruby-core:94184] [Ruby master Bug#7391] Allow to use require_relative from eval and irb environment Issue #7391 has been updated by jeremyevans0 (Jeremy Evans). Status changed from Assigned to Closed `require_relative` works in irb starting in Ruby 2.0: ``` $ irb19 irb(main):001:0> require_relative "test.rb" LoadError: cannot infer basepath from (irb):1:in `require_relative' from (irb):1 from /usr/local/bin/irb19:12:in `
' irb(main):002:0> $ irb20 irb(main):001:0> require_relative "test.rb" => true ``` ---------------------------------------- Bug #7391: Allow to use require_relative from eval and irb environment https://bugs.ruby-lang.org/issues/7391#change-80440 * Author: zzak (Zachary Scott) * Status: Closed * Priority: Normal * Assignee: shyouhei (Shyouhei Urabe) * Target version: * ruby -v: 1.9.3 * Backport: ---------------------------------------- =begin From github: https://github.com/ruby/ruby/pull/139 Before patch 1.9.3p125 :001 > require_relative "file" LoadError: cannot infer basepath from irb:1:in 'require_relative' from irb:1 from /home/lite/.rvm/rubies/ruby-1.9.3-p125-perf/bin/irb:16:in '
' After patch 1.9.3p125 :001 > require_relative "file" #=> true =end ---Files-------------------------------- require_relative_from_evail_and_irb.patch (3.35 KB) -- https://bugs.ruby-lang.org/ Unsubscribe: