Date : Sun, 09 Jun 2013 13:32:23 -0400
From : lists@... (Stephen Harris)
Subject: Acorn newline sequence
On Sun, Jun 09, 2013 at 06:21:39PM +0100, Dr. David Alan Gilbert wrote:
> The same is true on Linux; try the script command - you get the cr as
> well as lf recorded.
That's because the script command opens a new terminal device and records
activity from the "master" end of the psuedo-terminal.
$ tty
/dev/pts/0
$ script
Script started, file is typescript
sh-3.2$ tty
/dev/pts/4
This means that it's already gone through the TTY driver and the "stty"
settings I described earlier have had effect. In particular the NL->CRNL
translation. It's the same as if you'd hooked something to a serial
port and recorded all the output from that.
If you use the "tee" command to split the output of a command then
you don't see this.
--
rgds
Stephen