adding newlines at ends of files