class Toys::Utils::Exec::Executor
def initialize(exec_opts, spawn_cmd, block)
def initialize(exec_opts, spawn_cmd, block) @fork_func = spawn_cmd.respond_to?(:call) ? spawn_cmd : nil @spawn_cmd = spawn_cmd.respond_to?(:call) ? nil : spawn_cmd @config_opts = exec_opts.config_opts @spawn_opts = exec_opts.spawn_opts @captures = {} @controller_streams = {} @join_threads = [] @child_streams = [] @parent_streams = [] @block = block @default_stream = @config_opts[:background] ? :null : :inherit end