Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Debian 11 mate caja strange sorting order

Graphical Environments, Managers, Multimedia & Desktop questions.
Post Reply
Message
Author
user21345
Posts: 9
Joined: 2021-12-18 08:30
Has thanked: 1 time

Debian 11 mate caja strange sorting order

#1 Post by user21345 »

Hello,

when I sort in cara by file name the result is not in alphabetical order (see attachment). Although I can see in other directories the reasoning behind that implementation and that a lot of work went into that I would prefer the good old fashioned alphabetical order (ASCII characters only). I searched the web and came across a lot of things including feature requests but I did not find a solution.

So how do I get caja to sort file names in alphabetical order?

Kind Regards,
Hugo
.
Attachments
Screenshot at 2021-12-25 14-25-07.png
Screenshot at 2021-12-25 14-25-07.png (86.56 KiB) Viewed 8856 times

User avatar
bw123
Posts: 4015
Joined: 2011-05-09 06:02
Has thanked: 1 time
Been thanked: 28 times

Re: Debian 11 mate caja strange sorting order

#2 Post by bw123 »

They are sorted in numerical order, it's not really that strange, but it is different than I'm used to.
I created your filenames in the order your pic shows.

Code: Select all

$ ls > files
$ cat files
0001.flac
0001.lyr
001a.flac
001a.lyr
00fe.flac
00fe.lyr
00ff.flac
00ff.lyr
$ sort -n files
00fe.flac
00fe.lyr
00ff.flac
00ff.lyr
0001.flac
0001.lyr
001a.flac
001a.lyr
I found an old thread with a former solution, but it's from 2012. The file is probably relocated now.
Put the line
export LC_COLLATE=C
in the $HOME/.gnomerc file.
https://github.com/mate-desktop/caja/issues/27
resigned by AI ChatGPT

djk44883
Posts: 107
Joined: 2010-12-11 13:14
Has thanked: 2 times

Re: Debian 11 mate caja strange sorting order

#3 Post by djk44883 »

I use mate-desktop and struggle with this. Dot files are not always sorted first anymore - that's just wrong! I don't have/know the fix - as noted, I believe it does have something to do whit language settings, locales, and/or internationalization configurations.

Once I may have figured it out, then locales was upgraded and flubbed it up again... I think.

good luck :)

user21345
Posts: 9
Joined: 2021-12-18 08:30
Has thanked: 1 time

Re: Debian 11 mate caja strange sorting order

#4 Post by user21345 »

Hello bw123,

yes, you are right, it is sorted in "numerical order", whatever that means. But if I do sort without -n I get the sequence I expect and that I'd like to see.

./gnomerc does not exist of course and I have no idea what the equivalent in mate is called; that they changed all the names from gnome is very confusing though it looks as if it couldn't be avoided.

So anybody else any ideas how to get the correct string sorting order in caja (like from ls -l)?

Kind Regards,
Hugo

p.s: the link you had for the "feature request" is 10 years old. Very sad to see that such a fundamental fault has not been corrected in all that time... I'll probably get the caja source code and knit my own version, what is in the distribution will eventually get me into a nuthouse.
.

Post Reply