From: Brian Candler Date: 2003-07-30T16:39:01+09:00 Subject: Re: is it possible to pipe ruby to more / cat / arbitrary programs? On Wed, Jul 30, 2003 at 11:12:37AM +0900, Tuan Bui wrote: > I use Ruby as a scripting layer over another program, and I want to be > able to pipe the output of that program to unix programs. Is this > possible? I'm trying to do something like this: > > > #this will return output from the program in a string > programoutput = @program.send(input) > > #destprogram might be cat, grep, more, less, any such program > programoutput pipeoutput serr = Open3.popen3(destprogram) > > Does anyone know of a way to do this? I posted a solution which I think does what you want at http://ruby-talk.org/72502 eexcept I don't know what distinction you are trying to make between "programoutput" and "pipeoutput". Regards, Brian.