Class: Homebrew::DevCmd::Ruby

Inherits:
AbstractCommand show all
Defined in:
dev-cmd/ruby.rb

Instance Attribute Summary

Attributes inherited from AbstractCommand

#args

Instance Method Summary collapse

Methods inherited from AbstractCommand

command, command_name, #initialize, parser

Constructor Details

This class inherits a constructor from Homebrew::AbstractCommand

Instance Method Details

#runvoid

This method returns an undefined value.



26
27
28
29
30
31
32
33
34
35
36
# File 'dev-cmd/ruby.rb', line 26

def run
  ruby_sys_args = []
  ruby_sys_args << "-r#{args.r}" if args.r
  ruby_sys_args << "-e #{args.e}" if args.e
  ruby_sys_args += args.named

  exec(*HOMEBREW_RUBY_EXEC_ARGS,
       "-I", $LOAD_PATH.join(File::PATH_SEPARATOR),
       "-rglobal", "-rdev-cmd/irb",
       *ruby_sys_args)
end