Replace newline with OS specific EOL