From: ptkwt@...1.aracnet.com (Phil Tomson) Date: 2001-11-21T03:32:19+09:00 Subject: [ruby-talk:25935] Re: Checking if a file exists... In article <8D96EDA0AC04D31197B400A0C96C148003C04752@ossex1.corp.webb.net>, Ben Schumacher wrote: >I was wondering if somebody had an easy way of checking if a file exists on >a filesystem without using begin/rescue. I might be making this too >complicated on myself, but I can't seem to find any other way. I was hopign >there was something like a "File.exists" or similar. > if FileTest.exists?("filename") #read it else #it doesn't exist so don't try to read it end Phil