Added option of setting output file with -o file