class Aruba::Processes::DebugProcess
Run your command in ‘system()` to make debugging it easier. This will make the process use the default input and output streams so the developer can interact with it directly. This means that part of Aruba’s functionality is disabled. I.e., checks for output, and passing input programmatically will not work.
‘DebugProcess` is not meant for direct use - `DebugProcess.new` - by users. Only its public methods are part of the public API of aruba, e.g. `#stdin`, `#stdout`.
@private
Public Class Methods
Source
# File lib/aruba/processes/debug_process.rb, line 22 def self.match?(mode) mode == :debug || (mode.is_a?(Class) && mode <= DebugProcess) end
Use only if mode is :debug
Public Instance Methods
Source
# File lib/aruba/processes/debug_process.rb, line 63 def close_io(*); end
Close nothing
Source
# File lib/aruba/processes/debug_process.rb, line 77 def interactive? true end
Source
# File lib/aruba/processes/debug_process.rb, line 26 def start @started = true Dir.chdir @working_directory do Aruba.platform.with_replaced_environment(environment) do @exit_status = system(command, *arguments) ? 0 : 1 end end end
Source
# File lib/aruba/processes/debug_process.rb, line 54 def stderr(*) 'This is the debug launcher on STDERR. ' \ 'If this output is unexpected, please check your setup.' end
Return stderr
@return [String]
A predefined string to make users aware they are using the DebugProcess
Source
# File lib/aruba/processes/debug_process.rb, line 39 def stdin(*); end
Return stdin
@return [NilClass]
Nothing
Source
# File lib/aruba/processes/debug_process.rb, line 45 def stdout(*) 'This is the debug launcher on STDOUT. ' \ 'If this output is unexpected, please check your setup.' end
Return stdout
@return [String]
A predefined string to make users aware they are using the DebugProcess
Source
# File lib/aruba/processes/debug_process.rb, line 66 def stop(*) @started = false @exit_status end
Stop process
Source
# File lib/aruba/processes/debug_process.rb, line 73 def terminate(*) stop end
Terminate process
Source
# File lib/aruba/processes/debug_process.rb, line 60 def write(*); end
Write to nothing