added pretty print option