add CLI flag to write to stdout