[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Strange output by the "ls -l|less" command pipe in FC5



Joachim Backes [RHRK] wrote:
>> Using "ls -l|less " in FC5 gives a strange output on a fresh FC5 
>> installation.
>> Using "more" instead of "less" generates correct output. Did anybody 
>> make similar experiences?
>> 
>> ESC[00mtotal 916
>> -rw-r--r-- 1 root root 11942 Feb 12 09:50 ESC[00mLICENSEESC[00m

I'm sure I've tried that on FC5 and not seen the effect you mention.  It
certainly doesn't with FC4.

Mike McCarty:
> What you see here is the escape sequences for setting colors
> coming out of ls. You see, "less" is translating the escape
> sequences into graphic characters (like 0x1B is becoming "ESC").
> 
> Try this...
> 
> $ ls -l --color=never | less
> 
> If that looks ok (it should) try
> 
> $ ls -l --color=auto | less

Interestingly, FC4 seems to handle this well, and it's using this alias:
alias ls='ls --color=tty'.  So it looks like "less" behaves differently
between FC4 and FC5, rather than "ls".  There are options for how less
handles ANSI in the text, perhaps the defaults have changed.

-- 
(Currently running FC4, occasionally trying FC5.)

Don't send private replies to my address, the mailbox is ignored.
I read messages from the public lists.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]