Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: Notesfiles $Revision: 1.7.0.8 $; site ccvaxa Path: utzoo!linus!philabs!prls!amdimage!amdcad!decwrl!decvax!harpo!whuxlm!whuxl!houxm!ihnp4!inuxc!pur-ee!uiucdcs!ccvaxa!preece From: preece@ccvaxa.UUCP Newsgroups: net.unix-wizards Subject: Re: instability in Berkeley versus Message-ID: <2000020@ccvaxa> Date: Thu, 8-Aug-85 09:56:00 EDT Article-I.D.: ccvaxa.2000020 Posted: Thu Aug 8 09:56:00 1985 Date-Received: Mon, 12-Aug-85 21:53:15 EDT References: <9638@ucbvax.ARPA> Lines: 34 Nf-ID: #R:ucbvax.ARPA:-963800:ccvaxa:2000020:000:1657 Nf-From: ccvaxa.UUCP!preece Aug 8 08:56:00 1985 > > ps: K&P on this topic suggest using "pr" as a columnising filter. > > To my mind, "pr" is a paginator, its just as bad to make a paginator > > produce columns as some side effect as it is to make a directory > > listing program produce columns as a side effect - but of course, > > this was in "pr" from the beginning, so it is blessed... > It seems to me that a program for paginating might have to worry about > columns, but, yes this is probably not the best place to put a > columnator. On the other hand, it is possible to use the columnator > from pr from other programs, where with ls it's at very least kind of > difficult (create a file with the name of each line, do a ls -Cf, and > hope that there aren't two files with the same name? :-) ---------- How can you separate columnising from paginating? Clearly you can't columnise first, then page (you'd like the right column of a page to follow from the left column, not from the bottom of the left column of the last page). Nor can you page first, then columnise. You need a global process that alternates between grabbing enough material for one page and formatting it for display. That requires either a more complicated shell than Unix has or that the processes be turned into one program. It might be possible to embed the global knowledge in a shell script, but it would be a real pain. I think this is an example of something that is best done as a program. I tend to agree that ls should NOT do columnising for this same reason. Its columnising is wrong for pagination (it has to assume an infinite page length). -- scott preece gould/csd - urbana ihnp4!uiucdcs!ccvaxa!preece