removing temp and sorted file