Re: 'ls' name and 'ls | grep name' different
- Reply: Kyle Evans : "Re: 'ls' name and 'ls | grep name' different"
- In reply to: φ Dhénin Jean-Jacques : "'ls' name and 'ls | grep name' different"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 09 Mar 2024 16:37:11 UTC
On Sat, Mar 9, 2024 at 11:19 AM φ Dhénin Jean-Jacques <dhenin@gmail.com> wrote: > Bonjour, > > I explain it as simple as possible: > > :; set | egrep 'LC_A|LANG' > GDM_LANG=fr_FR.UTF-8 > LANG=fr_FR.UTF-8 > LC_ALL=fr_FR.UTF-8 > SLIM_LANG=fr_FR.UTF-8 > > :; ls -i 1989* ; ls -i | grep 1989 ; ls -ib 1989* ; ls -ib | grep 1989 > 9920 1989 Amn*??*sia.mp4 > 9920 1989 Amn*é*sia.mp4 > 9920 1989 Amn\303\251sia.mp4 > 9920 1989 Amn\303\251sia.mp4 > > Bonjour J-J – It's not that the pipe modifies the stream, it's that 'ls' has decided that 'e-accent-aigu' is unprintable in the current locale. Try ls -B and then investigate the locale. *-B* Force printing of non-printable characters (as defined by *ctype*(3) <https://man.freebsd.org/cgi/man.cgi?query=ctype&sektion=3&apropos=0&manpath=FreeBSD+14.0-RELEASE+and+Ports> and current locale settings) in file names as *\**xxx*, where *xxx* is the numeric value of the character in octal. This option is not defined in IEEE Std 1003.1-2008 ("POSIX.1"). >