Nautilus: How are files sorted

filenamesnautilussort

I am quite new to Debian 8.4. I am not sure if this is the right community on stackexchange to pose this question. Please tell me, if not.

My question: I am using the Nautilus file manager. I view a directory with some files in list view. Then I click on the bar with 'Name' on it. The order of sorting changes. My question is: How does Nautilus sort the files if I click on this button. More specifically, what is the sort order? e.g I have four files - and _ and a and b. If I have them sorted in ascending order (I call it this way, if a is before b) then _ will be before -. What is the general rule for sorting in Nautilus? And how could I find this information on my own – for example in the source code? I spent half an hour searching the web…

Best Answer

"_" or "-" or other symbols do not have any impact at all, only the following letters are relevant for sorting. It's really annoying but I guess sort options are too hard to code for the devsā€¦

Related Question