output files to temporary directory