I'm trying to check if a file exists with RoR but it keeps saying this file does not exist and I can't understand why.
if File.exist?('~/Desktop/test.xls')
p 'File EXISTS'
else
p 'Cannot find any file'
end
Of course the file exists and I can access it with the terminal using 'ls'.
The script is into the scripts folder of my rails app.
Thanks for any help