Check if a file exists
The File
module provides an exists?/1
to check if a file exists.
true = File.exists?("exists.txt")
false = File.exists?("doesnt_exist.txt")
The File
module provides an exists?/1
to check if a file exists.
true = File.exists?("exists.txt")
false = File.exists?("doesnt_exist.txt")