From: Ross Bamford Date: 2006-01-05T03:33:09+09:00 Subject: Re: Searching a file for keywords? On Wed, 04 Jan 2006 17:53:50 -0000, Joel VanderWerf wrote: > Ross Bamford wrote: >> File.open('/proc/partitions') do |f| >> puts f.grep(/hda/) >> end > > irb(main):008:0> puts IO.read('/proc/partitions').grep(/hda/) Ah thanks, that's better. -- Ross Bamford - rosco@roscopeco.remove.co.uk