for a list of the current path under the directory (not the list of directories) method, and share with you ~ ~
1. Using ls-d with wildcard characters
ls-d * *
2, ls-f with grep query with/end of the content
-F: Displays the directory behind the/
ls-f | grep "/$"
3, ls-l with grep query to start with D content
ls-l | grep "^d"
4, find, here to use a parameter:-maxdepth (maximum number of directories)
find.-maxdepth 1-type D
-maxdepth 1: Indicates that only the first level directory is listed
-maxdepth 2: List the directories to the second tier, and so on
There is also an interesting parameter:-mindepth(minimum number of directories)
in other words,-mindepth 5 represents only a list of more than 5 stories.
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/6D/42/wKiom1VfDwXRpqjpAAHqCcYFzOU997.jpg "border=" 0 " Style= "Margin:0px;padding:0px;border:medium none;line-height:22.3999996185303px;font-family: ' Song Body ', Arial, Helvetica, ' San-serif '; Font-size:14px;white-space:normal;background-color:rgb (255,255,255); "/>
This article is from the "Just for Fun" blog, so be sure to keep this source http://linuxmz.blog.51cto.com/9860985/1657124
"Column directory" of Shell programming learning