reorder files and new output files