sort the files so they are processed in a consistent order