Hello Jean-Luc,

Jean-Luc Coulon wrote:
> Thank you for the clear and detailed informations.

You are most welcome.  I know it was a confusing case.

> Yes, *I* use cat (display a file on a terminal) as you said since... well...
> maybe 1976 ;) But in these years, the standard output was a belt printer.

I started sometime around 1980 on a Honeywell with paper terinals.
Well...  Probably earlier on a Radio Shack TRS-80 which I could play
with at the local store.  It took a couple of more years before I
encountered my first Unix system.  But I have been here ever since!

> And yes, the culprit was the prompt. I'm using zsh with a fancy prompt.
> Switching to a basic prompt solved the problem.

I was confident that was the problem. :-)

> I was confused because this file used to be "displayable" with the cat
> command (which is very handy to do this kind of thing).

I can guess that your prompt has probably gotten fancier.  But
regardless this is a good thing to find anyway.  Because shouldn't
that troublesome VERSION file have a newline at the end?  Sounds like
a worthwhile task to go poke at on that project.

> For those interested in, the manpage of the 1st edition of UNIX manual was
> saying:
> 
> 11/3/71                                                   CAT (I)
> NAME         cat -- concatenate and print
> SYNOPSIS     cat file1 ...
> DESCRIPTION  cat reads each file in sequence and writes it on
> the standard output stream.  Thus:
> cat file
> is about the easiest way to print a file.  Also:
> cat file1 file2 >file3
> is about the easiest way to concatenate files.
> If no input file is given cat_ reads from the
> standard input
> 
> So there are some excuses using cat as a "way to print a file".

Yes.  I didn't want to mention the man page for it because of that
text mentioning "printing".  But I think it is actually incorrect as
soon as paper printing terminals were replaced with CRT terminals.
Back in the days when everyone used a teletype or the later paper
terminals then using cat to emit a file to the terminal does print it
because the terminal was a paper terminal.  But as soon as CRTs came
along I think that documentation became incorrect because on a CRT
emitting the file to the terminal no longer printed it.  But without a
real pressing need to change the documentation it still stands all of
the way to this day regardless of the lack of anyone having seen a
paper terminal in many years.

But you have forgotten the other venerable claim for using 'cat' as
well.  It has often been claimed that a Unix wizard is one that among
other things writes device drivers with cat redirected from the
terminal. :-)

Bob

Reply via email to