Article View: net.bugs
Article #480"proper UNIX text file" ???
From: Curtis Jackson
Date: Mon, 21 Oct 1985 14:46
Date: Mon, 21 Oct 1985 14:46
21 lines
1564 bytes
1564 bytes
In article <2235@brl-tgr.ARPA> gwyn@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
Technical Details
Message-ID:
<901@burl.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!rcjReferences:
<23@pixel.UUCP> <2235@brl-tgr.ARPA>Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site burl.UUCP Path: arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!rcj From: rcj@burl.UUCP (Curtis Jackson) Newsgroups: net.bugs Subject: "proper UNIX text file" ??? Message-ID: <901@burl.UUCP> Date: Mon, 21-Oct-85 10:46:40 EDT Article-I.D.: burl.901 Posted: Mon Oct 21 10:46:40 1985 Date-Received: Tue, 22-Oct-85 05:22:20 EDT References: <23@pixel.UUCP> <2235@brl-tgr.ARPA> Reply-To: rcj@burl.UUCP (Curtis Jackson) Organization: AT&T Technologies, Burlington NC Lines: 21