Add option to sort base on certain locale. (#1818)

* Add support for localized sorting

* Switch go-locale module; Use collate option for natural sorting

* Doc and error message improvement

* Simplify predicated checking of localized sorting.

* Improve error handling of `set locale` command
This commit is contained in:
陆离 authored and GitHub committed 2024-11-02 00:12:21 +11:00
1 parent 4079aead14
commit 3f63bc980f
8 files changed
+189 -19

No files matched your search

+2 -1
View File
@@ -3,17 +3,18 @@ module github.com/gokcehan/lf
go 1.18
require (
github.com/Xuanwo/go-locale v1.1.2
github.com/djherbis/times v1.6.0
github.com/fsnotify/fsnotify v1.8.0
github.com/gdamore/tcell/v2 v2.7.4
github.com/mattn/go-runewidth v0.0.16
golang.org/x/sys v0.26.0
golang.org/x/term v0.25.0
golang.org/x/text v0.18.0
)
require (
github.com/gdamore/encoding v1.0.0 // indirect
github.com/lucasb-eyer/go-colorful v1.2.0 // indirect
github.com/rivo/uniseg v0.4.3 // indirect
golang.org/x/text v0.14.0 // indirect
)