Re: Simple sh or alias to list directories
On Tue, Oct 17, 2000 at 02:36:05PM +0000, Thomas Halahan wrote:
> Hello,
> I am trying to determine an easy alias or sh script that will list
> only the directories in a directory. It should have similar
> functionality to the ls command. E.g.
> [tom]$ lsd ~
> should list only the directories in my home folder, not the files.
> Does anyone know of a way to do this please?
>
In zsh, do:
ls -d *(/)
(you may or may not need to setup extended globbing of various kinds. See
the docs.)
Michael.
Reply to: