script to cat last output file