On Jan 30, 2006, at 12:09 PM, charlie bowman wrote: > irb(main):002:0> Dir.mkdir(".timeclock") > won't the above faile once the directory is created. I need to run a > check each time the application is ran. Yes, that's why you wrap it in an if (or unless) statement. unless File.exist?(".timeclock") Dir.mkdir(".timeclock") end # Optionally make sure .timeclock is a directory unless File.directory?(".timeclock") puts ".timeclock is a not a directory." exit( 1 ) end # do whatever.