Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 07 Jul 2000 19:17:25 +0100
From:      Peter McGarvey <Peter.McGarvey@telinco.net>
To:        eric.boucher24@sympatico.ca
Cc:        FreeBSD <freebsd-questions@FreeBSD.org>
Subject:   Re: Question about ls -b
Message-ID:  <39661EB5.257D7CD0@telinco.net>
References:  <396603F5.577B50B2@sympatico.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
Boucher Eric wrote:
> 
> Hi,
> 
> I wanted to know something about the command :     ls -b
> 
> It is suppose to show the non printable character in the form   /ddd
> in hexadecimal.
My man page says:

     -b      As -B, but use C escape codes whenever possible.

and

     -B      Force printing of non-graphic characters in file names as
\xxx,
             where xxx is the numeric value of the character in octal.
 

> 
> But doesn't seem to put the exact value by converting the hexadecimal
> number to the

So it's not hex, it's octal

> 
> ASCII code. For example, if a name of one of my file contains the ASCII
> character 130, when I type the ls -b command, the output show me :
> /202 , which is the number 516, not 130  (maybe it's not the exact
> number, but it's close to it, I do it by memory, it's only to show that
> it's not the correct number.)
> 

130 -> 82 in hex -> 202 in octal

so it appears to be working fine....

I would say RTFM, but I won't as I don't want to start a flame war ;-)


-- 
TTFN, FNORD

Peter McGarvey, Unix Administrator
Network Operations Center, Telinco Limited


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?39661EB5.257D7CD0>