trim long filenames