Sha256: f830afddb3bd969116053ec49325c457079081b3e14263ea4dc24a86297ee6f2
Contents?: true
Size: 413 Bytes
Versions: 38
Compression:
Stored size: 413 Bytes
Contents
require 'rbconfig' module RubyForker # Forks a ruby interpreter with same type as ourself. # jruby will fork jruby, ruby will fork ruby etc. def ruby(args, stderr=nil) config = ::RbConfig::CONFIG interpreter = File::join(config['bindir'], config['ruby_install_name']) + config['EXEEXT'] cmd = "#{interpreter} #{args}" cmd << " 2> #{stderr}" unless stderr.nil? `#{cmd}` end end
Version data entries
38 entries across 38 versions & 5 rubygems