to sort files under the subdirectory by date