Re: Proposed patch - psql wraps at window width - Mailing list pgsql-hackers

From Bryce Nesbitt
Subject Re: Proposed patch - psql wraps at window width
Date
Msg-id 48152A7D.70104@obviously.com
Whole thread Raw
In response to Re: Proposed patch - psql wraps at window width  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Proposed patch - psql wraps at window width  (Gregory Stark <stark@enterprisedb.com>)
List pgsql-hackers

Tom Lane wrote:
> Bruce Momjian <bruce@momjian.us> writes:
>   
>> I don't see that behavior here on Ubuntu 7.10:
>>     $ COLUMNNS=120 ls -C |cat
>>     archive       cd    initrd      lost+found  proc  srv  usr
>>     basement.usr  dev   initrd.img  media       root  sys  var
>>     bin           etc   laptop      mnt         rtmp  tmp  vmlinuz
>>     boot          home  lib         opt         sbin  u    win
>>     $ ls --version
>>     ls (GNU coreutils) 5.97
>>     
> Well, it's *certainly* gonna ignore "COLUMNNS".
>
>             regards, tom lane
>   
I'm having trouble seeing the relevance, either way.  First many shells 
don't set $COLUMNS at all (readline does it for psql).  And most shells 
that set $COLUMNS don't export it.  So most people get different output 
from:
# ls -C# ls -C | cat

Unless they are in the habit of doing:
# COLUMNS=$COLUMNS ls -C |cat

I think it's too weird to default pipes to whatever the terminal width 
happens to be.  So that leaves you with an explicit command to set the 
width for pipes.
                                       -Bryce


Echo $MANWIDTH



pgsql-hackers by date:

Previous
From: "Brendan Jurd"
Date:
Subject: Re: Invalid to_date patterns (was: [PATCHES] [GENERAL] ISO week dates)
Next
From: Jeff MacDonald
Date:
Subject: quirk using 'ltree' module: paths ending with a dot result in cryptic error message