Duplicate stdout and stderr to both command line and file.