Ruby/File Directory/join
Материал из Wiki.crossplatform.ru
Join file name and folder name together
File.join("home","matz") # => "home/matz": relative File.join("","home","matz") # => "/home/matz": absolute
use File.join to put together a filename using directory names and a final filename:
File.join("full", "path", "here", "filename.txt")