Editing and formating the file