You can use Process.spawnand Process.wait2:
pid = Process.spawn 'your.exe', '--option'
pid, status = Process.wait2 pid
Your program will be executed as a child process of the interpreter. In addition, it will behave as if it were called from the command line.
You can also use Open3.popen3:
require 'open3'
*streams, thread = Open3.popen3 'your.exe', '--option'
streams.each &:close
status = thread.value
, IO. , .
, . , , script.
, , .