change a few old "echo >> $tempfile" lines to use report()