gokcehan / lf

Terminal file manager
MIT License
7.79k stars 331 forks source link

setlocal conflicts with other sorting #1858

Open simonhughxyz opened 1 day ago

simonhughxyz commented 1 day ago

When using setlocal for sorting and then change sorting manually afterwards in the same folder it does not sort the folder properly.

Tried with: setlocal ~/Downloads/ sortby time; set info time Followed by :set sortby size and set info size to be able to see the sizes.

The expected behavior is for the files to be sorted by file size, but they appear to be shuffled randomly.

joelim-work commented 1 day ago

This is expected behavior:

Generally setlocal is used for directories for which a particular setting should be 'fixed'. I don't think it's worth adding a third layer of setting which can temporarily override setlocal, but for your case maybe you can try setlocal ~/Downloads/ sortby size.

Also just a note that you can use set info size:time if you want to see both at the same time, if it makes it easier.