"proper UNIX text file" ???

Curtis Jackson rcj at burl.UUCP
Tue Oct 22 00:46:40 AEST 1985


In article <2235 at brl-tgr.ARPA> gwyn at brl-tgr.ARPA (Doug Gwyn <gwyn>) writes:
>Many UNIX text-file utilities will discard a (necessarily final)
>text line that does not end in a newline.  Quite simply, such a
>file is not a proper UNIX text file.

I think that the \User Guide to the UNIX System/ rebutts this as well as
I could:

"In the UNIX system, files have no internal structure; they are simply
a finite sequence of arbitrary characters."

A Unix file is a series of bytes, nothing more is needed to make it a
'proper' UNIX text file.  The reason that sed and some (few) others discard
the last few bytes after the last newline is because these utilities work
on 'lines' of input -- and the definition used by all (most?) of them for
a line is zero or more non-newline characters followed by a newline.
-- 

The MAD Programmer -- 919-228-3313 (Cornet 291)
alias: Curtis Jackson	...![ ihnp4 ulysses cbosgd mgnetp ]!burl!rcj
			...![ ihnp4 cbosgd akgua masscomp ]!clyde!rcj



More information about the Net.bugs mailing list