How can ls be flagged to sort .-prefixed hidden directories and files in groups so that its output is sorted as visible directories, hidden directories, visible files, then hidden files?
I currently have ls aliased to ls -lG --color --group-directories-first which groups directories first, but visible and hidden directories are mixed together.
Instead, the output of ls should be:
visibleDirectoryA
visibleDirectoryB
.hiddenDirectoryA
.hiddenDirectoryB
visibleFileA
visibleFileB
.hiddenFileA
.hiddenFileB
en_AU.UTF8. BTW,LANG=C ls ....fails to reproduce (and, in fact, will even sort a directory name like!foobefore any of the .hidden directories - strict ascii value sort rather than a natural sort).LANG=en_US.UTF-8 LANGUAGE= LC_CTYPE=en_US.UTF-8 LC_NUMERIC="en_US.UTF-8" LC_TIME="en_US.UTF-8" LC_COLLATE="en_US.UTF-8" LC_MONETARY="en_US.UTF-8" LC_MESSAGES="en_US.UTF-8" LC_PAPER="en_US.UTF-8" LC_NAME="en_US.UTF-8" LC_ADDRESS="en_US.UTF-8" LC_TELEPHONE="en_US.UTF-8" LC_MEASUREMENT="en_US.UTF-8" LC_IDENTIFICATION="en_US.UTF-8" LC_ALL=