This project is closed and read-only.
Actions
Bug #1005
closedStrange behaviour of File.directory? under Windows
Bug #1005:
Strange behaviour of File.directory? under Windows
Description
=begin
Under Windows:
C:>ruby --version
ruby 1.8.7 (2008-08-11 patchlevel 72) [i386-mswin32]
C:>irb
irb(main):001:0> File.directory? ".."
=> true
irb(main):002:0> File.directory? "..."
=> true
irb(main):003:0> File.directory? ".............."
=> true
Under Unix:
ruby --version¶
ruby 1.8.5 (2006-08-25) [i386-linux]
irb¶
irb(main):001:0> File.directory? ".."
=> true
irb(main):002:0> File.directory? "..."
=> false
irb(main):003:0> File.directory? "........"
=> false
I.e. it looks like File.directory? returns true under Windows if filename contains any number of dots.
Sorry, could'n test this exact Ruby version under Unix.
=end
Actions