Discover Linux has a good command, tree, can put the directory in the form of trees, but also support very powerful parameters.
But by default is not with, you have to go to install, first to download its code: http://mama.indstate.edu/users/ice/tree/
I downloaded is 1.7.0, is a tgz package, unzip it.
Then modify its compilation configuration file, if you use Linux, you do not have to change, if you and I use the same Mac OS X, open makefile, according to the comments in the makefile, the Linux section commented out, and then cancel the Mac OS x part of the comments, such as:
...... # Linux defaults:33 #CFLAGS =-ggdb-wall-dlinux-d_largefile64_source-d_file_offset_bits=64 #CFLAGS =-o4-wall -dlinux-d_largefile64_source-d_file_offset_bits=64 #LDFLAGS =-s ... # Uncomment for OS x:56 #CC =cc cflags=-o2-wall-fomit-frame-pointer-no-cpp-precomp #LDFLAGS = #MANDIR =/usr/s Hare/man/man1 OBJS+=STRVERSCMP.O ...
Save Exit, execute:
$make
No problem, then proceed:
$sudo make Install
Try it now, I like to use it:
$tree-SHC
This is the execution effect:
As a reminder, it can be time-consuming to execute this command in a directory with a lot of content.
From:http://www.cnblogs.com/guogangj/p/3957458.html
The tree command for Linux