I looked into the mundane appearing question to change the sorting
order of the 'ls' command. I wanted to have non-'alnum' characters
come first. The two obvious ways - looking into the (many dozens!)
of options supported by 'ls', and setting LC_COLLATE (or LC_ALL) -
strangely, didn't work or show anything appropriate.
On 2026-10-14, Janis Papanagnou <janis_papanagnou+ng@hotmail.com> wrote:
I looked into the mundane appearing question to change the sorting
order of the 'ls' command. I wanted to have non-'alnum' characters
come first. The two obvious ways - looking into the (many dozens!)
of options supported by 'ls', and setting LC_COLLATE (or LC_ALL) -
strangely, didn't work or show anything appropriate.
That would depend on the operating system's ls(1) implementation,
but FreeBSD's does honor LC_COLLATE:
[...]
The sysadmin would have to create a locale with your particular
collation order.
I interpret your post that you see no other way, specifically not
any way to obtain such a function "on the shell command-line level"
(as I had written in my OP to be seeking)?
| Sysop: | Jacob Catayoc |
|---|---|
| Location: | Pasay City, Metro Manila, Philippines |
| Users: | 5 |
| Nodes: | 4 (0 / 4) |
| Uptime: | 498677:41:03 |
| Calls: | 212 |
| Calls today: | 3 |
| Files: | 910 |
| D/L today: |
31 files (22,593K bytes) |
| Messages: | 69,826 |