Okay. Not sure how much detail I need to go into so bear with me please.
Back in the stone age computers often used a device called a Teletype Model 33 or ASR 33 Teletype machine for console I/O. This was often abbreviated to TTY, and we still use "tty" today but not to refer to ASR 33's. Anyhow, the ASR 33 was very much like a typewriter in operation; it pressed an inked ribbon against paper to produce printout. There was a moveable typebox that moved from left to right printing characters as it arrived. When it reached the rightmost limit, it would stay there overtyping whatever was typed in the last character position until it received a special character called a "carriage return". This would cause the print mechanism to move back to the left hand side of the paper.
It would then be in a position to overtype the line it had just printed, so another control character would be sent to the TTY called a "line feed". This would cause the platen to advance the paper one line.
The upshot of this is that after printing a line, you had to send a carriage return and a line feed, which came to be known as the "line ending characters". The ASCII codes for these special characters were 015 and 012 respectively in octal. We don't use octal any more so today we'd print them as 0x0D and 0x0A.
The ASR33's and similar devices such as the IBM 2741 (which used EBCDIC, not ASCII usually) were slow and noisy and eventually were phased out and replaced by devices with a CRT display instead of paper. These devices were commonly known as "glass TTYs". I'll leave it to the reader to figure out how "glass TTY" was often pronounced.
Around this time we had the introduction of the microprocessor and a number of operating systems developed to run on these systems. It was also realized that the carriage return and linefeed didn't cause physical movement on anything and merely designated the end of a printed line, so it wasn't strictly necessary to have both. The TRS-80 and Apple][e and, later, pre-Intel-based Macintoshes used carriage return (0x0D) only to signify the end of a line. Commodores (Amigas) used linefeeds (0x0A) only, as did Unix, Multics, and many other "big iron" OSes. MS-DOS and its derivative/successor continued to use the CR/LF 0D0A sequence.
The Create web IDE uses 0x0D as a line ending character. Linux uses 0A as a line ending character. It will recognize 0x0D as a carriage return, and that's exactly what it does -- returns the cursor to the beginning of the line without advancing to the next line. So when I export a sketch and attempt to display it on my terminal with a command such as "cat mysketch.ino", all I see is the last line and fragments of previous lines on the right if they were longer than the last line. If I load the sketch into an editor such as vim or nano or joe, it renders the carriage return characters as Ctrl-M or ^M characters and not as newlines.
So I have to filter the sketch before I can work with it to translate the CR's to LF's.