From: "Cai I." Date: 2010-11-04T17:52:59+09:00 Subject: Can I run windows command line app interactively? I want to do something like this: # open a session @session = IO.popen('cmd.exe', 'r+') # run a command and process outputs @session.puts('dir') @session.each do |line| p line end # run a command line application @session.puts('robocopy.exe ......') @session.each do |line| p line end The issue is that "@session.each" never stop. It waits when cmd.exe waiting for input. So the scripts hang. Thanks! -- Posted via http://www.ruby-forum.com/.