Hi!
Can anyone tell me the way to get rid of the intermediate temporary file 
in the IPC process?  -Thanks



require "tempfile"
temp = Tempfile.new("temp")
name = temp.path

puts "Enter first command"
cmd1 = gets
puts "Enter second commnd"
cmd2 = gets

IO.popen("-") do |mypipe|
   if mypipe
      listen = mypipe.read
      temp.puts listen
      temp.close
      temp.open
      cmd3 = sprintf("%s %s %s", cmd2.chomp!,"<",name)
      system(cmd3)
      temp.close(true)
   else
      system(cmd1.chomp!)
   end