class CommandLineScript

Attributes

command[R]
exit_status[R]
pid[R]
stdin[R]
stdout[R]
sterr[R]

Public Class Methods

new(command) click to toggle source
# File lib/jenkins_util/command_line_script.rb, line 9
def initialize(command)
  @command = command

  LoggerUtil.log.debug("Executing: \"#{@command}\"")
  status = Open4.popen4(@command) do |pid, stdin, stdout, stderr|
    @pid = pid
    @stdin = stdin
    @stdout = stdout.readlines
    @error = stderr.readlines
  end

  @exit_status = status.exitstatus
end