Adding no_save option and passing options and output string to write_output