lite-xl-plugins icon indicating copy to clipboard operation
lite-xl-plugins copied to clipboard

feat: [sort] add alphabetic descending and natural sorting

Open SpotlightKid opened this issue 3 years ago • 3 comments

Natural sorting function implemented after http://notebook.kulchenko.com/algorithms/alphanumeric-natural-sorting-for-humans-in-lua (version four).

SpotlightKid avatar Dec 24 '21 18:12 SpotlightKid

I like it! The only thing I can think of is that it may make sense to symlink sort:sort to sort:sort-alpha; just so that it continues to work for people that've bound this to a key already; though this isn't critical (I can't imagine too many people have this on hotkey).

adamharrison avatar Dec 29 '21 17:12 adamharrison

Yes, I thought about that too. So would you suggest simply binding function() do_sort(sort_alpha) end to ["sort:sort"] as well as ["sort:sort-alpha"]?

SpotlightKid avatar Dec 30 '21 00:12 SpotlightKid

That makes sense to me.

adamharrison avatar Dec 30 '21 00:12 adamharrison

Closing this since I'm cleaning up my unmerged/unfinisged PRs and this is now conflicting and I don't use lite-xl anymore.

SpotlightKid avatar Aug 24 '23 12:08 SpotlightKid