bug-coreutils
[Top][All Lists]
Advanced

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

sort order changed in "sort" and "ls".


From: Rogier Wolff
Subject: sort order changed in "sort" and "ls".
Date: Tue, 10 Mar 2009 15:28:09 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

Dear coreutils-developers, 

I just noticed that ls sorted my directory in an unusual way. I was
writing up a bugreport, and was saying: It's odd that ls would sort
differently than "sort" would, and found out that sort has been
changed as well.

Sort has an option to trigger the observed behaviour: -f. 

This works on an older instance of "sort" that I found, which was
compiled by debian in 2004.

My current installations, debian and Ubuntu act as if the -f option is
always in place. No change in behaviour is observed between adding or
removing the -f option on sort. No flag to request or negate this
behaviour could be found for ls.

To reproduce: 

mkdir test-ls
cd test-ls
touch A C E G I K b d f h j
ls -l           # Should imho yield the files in the order above.
ls -1 | sort    # same. 
ls -1 | sort -f # should give: A b C d E f G h I j K


I understand the arguments for sorting this way. However changing a
standard unix tool should not be done lightly. I'm counting on the
uppercase files to be sorted BEFORE the lower case files in my
scripts. At the very very least it should be possible to
enable/disable this behaviour with an option flag.


Regards, 

        Roger Wolff. 

P.S. It seems my shell is similarly broken. 

-- 
** address@hidden ** http://www.BitWizard.nl/ ** +31-15-2600998 **
**    Delftechpark 26 2628 XH  Delft, The Netherlands. KVK: 27239233    **
*-- BitWizard writes Linux device drivers for any device you may have! --*
Q: It doesn't work. A: Look buddy, doesn't work is an ambiguous statement. 
Does it sit on the couch all day? Is it unemployed? Please be specific! 
Define 'it' and what it isn't doing. --------- Adapted from lxrbot FAQ




reply via email to

[Prev in Thread] Current Thread [Next in Thread]