From: Joel VanderWerf Date: 2008-10-26T04:08:48+09:00 Subject: Re: Join all text files in a folder, with a single line of Ruby code William James wrote: > "We don't need no stinkin' loops!" > > ruby -e"puts ARGF.to_a" *.txt >merged Cheating a bit: ARGV.replace Dir['*']; print ARGF.read Not recommended, though, since it reads all the data into memory and steps on ARGV. -- vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407