Re: ls'ing dirs before files
On Fri, 26 Jul 2002 23:03:43 +0200, martin f krafft wrote:
>sometime last year, the /bin/ls behaviour changed to sorting files and
>dirs interspersed. how can i make /bin/ls first list all dirs, then
>all files, and each of them sorted by filename within itself?
What a neat little opportunity for self-edification :)
My first thought was to do ls -l | sort. That will order as directory,
link, and regular files, but mess up order within the class, since
permissions are next, then nodes, then owner, then... :(
So now I'll read the FMs for sed and regex and maybe awk to see about
reworking the sort order. Don't wait up for me, Mom. I'll be late.
--
gt kk5st@swbell.net
If someone tells you---
"I have a sense of humor, but that's not funny."
---they don't.
--
To UNSUBSCRIBE, email to debian-user-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Reply to: