List only directories using ls
    $ ls -l | grep “^d”
    $ find . -type d -maxdepth 1 -mindepth 1
    $ tree -d -L 1
    $ ls -d */
    $ tree -fid
    $ find . -type d -printf ‘%P\b’
    $ ls -d */ | xargs -l basename
    $ find . -maxdepth 1 -mindepth 1 -type d -print0 | xargs -0 | sed ’s/.\//\n/g’
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License