Christian Madsen wrote: > I found a funny feature of Ruby tonight: if possible, commandline > arguments are automatically globbed. For instance in a directory with > one file foo.bar: > > test.rb *.bar > => ARGV = ['foo.bar'] > > test.rb *.html > => ARGV = ['*.html'] > > Even the ** kind of globbing works. > > I've tried to search google and the pickaxe book, but haven't found any > documentation on this feature. The globbing isn't happening in Ruby, it's happening in the shell that launches Ruby. In a directory with only foo.bar present, this will work: $ echo *.bar foo.bar In a directory with many files, all will be globbed (except "." and ".."), if you: $ echo * (long list) This is standard shell behavior. It precedes execution of the command at the left. -- Paul Lutus http://www.arachnoid.com