4 # Forks a ruby interpreter with same type as ourself.
5 # juby will fork jruby, ruby will fork ruby etc.
6 def ruby(args, stderr=nil)
7 config = ::Config::CONFIG
8 interpreter = File::join(config['bindir'], config['ruby_install_name']) + config['EXEEXT']
9 cmd = "#{interpreter} #{args}"
10 cmd << " 2> #{stderr}" unless stderr.nil?