On Sat, Feb 24, 2001 at 01:19:22PM +0900, David Alan Black wrote: > Have a look at Dir.glob, compared with Dir.new: > > irb 1> Dir.new(".").entries > ==>[".", "..", "somefile", "anotherfile", "thirdfile"] > irb 2> Dir.glob("*") > ==>["somefile", "anotherfile", "thirdfile"] Interestingly... $ mkdir "test directory" $ touch touch test\ directory/foo $ irb irb(main):001:0> Dir.glob("test directory/*") [] Is this a bug? Dir.glob works fine for directories without a space in their names, but it always returns an empty array on directories with spaces, AFAICT. I've tried the latest CVS snapshot and the problem still occurs. Is this a bug with Ruby or am I just being stupid? ;-) > Example of how you might use this (together with some > implicit suggestions about the code logic :-) Thanks for the suggestions -- I appreciate them. Thanks also to everyone else who helped me. I think I've got everything worked out now, except for the annoying problem above. Thanks, Neil -- Neil Conway <neilconway / home.com> Get my GnuPG key from: http://klamath.dyndns.org/mykey.asc Encrypted mail welcomed Hard work never hurt anyone - but why take chances?