From: Mark Wilson Date: 2003-03-18T04:22:45+09:00 Subject: irb as a shell Just a note. In the past day or two I've started to use irb as a shell to work in, and it's very helpful, although not earth-shattering. For example, I did the following in irb to unzip a bunch of files in my working directory: system("ls *gz > list") a=File.open("list","r") b=a.readlines b.each { |f| system("gtar -zxf #{f}") } b.each { |f| system("rm -rf #{f}") } I think this could be done with an ordinary shell, using xargs maybe, but I know how to do it in Ruby. If you have a more elegant way to write the Ruby lines, let me know. Looking at it, I can see that if I remembered the directory methods I could make the first 3 lines one line.