Added renaming of output files