fa.openbsd.tech
[Top] [All Lists]

Re: [patch] ps.c ps.1 Disregard terminal width when STDOUT is not a tty

Subject: Re: [patch] ps.c ps.1 Disregard terminal width when STDOUT is not a tty (take 2)
From: Tobias Ulmer <tobiasu@xxxxxxxx>
Date: Mon, 21 Jul 2008 16:18:45 UTC
Newsgroups: fa.openbsd.tech

On Mon, Jul 21, 2008 at 05:17:31PM +0200, Paul de Weerd wrote:
> On Mon, Jul 21, 2008 at 10:58:49AM -0400, Nick Guenther wrote:
> | > No way to tell ps to create terminal width output for ps ... | grep
> | > pipes any more.
> | 
> | Huh? How do you use that? Isn't the point that grep searches records
> | of related information? Why would you ever want it to be dealing with
> | results split across lines?
> 
> `ps | colorize` on your 80char wide terminal (with colorize being a
> fictional tool that marks up stdin with color coding). Or how about
> just simply `ps | sort` ? I can think of lots of programs I might want
> to pipe ps output into that still displays on my terminal with (at
> most) 80 char lines.
> 
> This entire discussion also reminds me of the article I once read (but
> now can't find anymore) that explained why ls(1) doing isatty was such
> a bad idea (along with cat -n and others). Anyone know what article
> I'm talking about ?

Probably http://gaul.org/files/cat_-v_considered_harmful.html

> 
> Cheers,
> 
> Paul 'WEiRD' de Weerd
> 
> -- 
> >++++++++[<++++++++++>-]<+++++++.>+++[<------>-]<.>+++[<+
> +++++++++++>-]<.>++[<------------>-]<+.--------------.[-]
>                  http://www.weirdnet.nl/                 


<Prev in Thread] Current Thread [Next in Thread>