On Mon, Apr 16, 2007 at 11:56:48AM +0900, Sonny Chee wrote:
> I'm actually to trying to solve the following problem. I've been 
> redirecting the contents of a_file to an os_command, ie:
> 
> os_command < a_file
> 
> Usually a_file is very small and I have to create this file before 
> invoking the os_command.  Is it possible to avoid the creation of a_file 
> and just pass its contents directly to os_command?

If you are running os_command from Ruby, use IO.popen to run it. You then
get an IO object for a pipe to squirt data at it.