Writing config file with pretty format