first version of getting directory and file names