added $directory file resource