8000 tree 命令添加实例 · iCodingStar/linux-command@1ea87bf · GitHub
[go: up one dir, main page]

Skip to content

Commit 1ea87bf

Browse files
authored
tree 命令添加实例
1 parent a417715 commit 1ea87bf

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

command/tree.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,4 +91,13 @@ tree /private/ -L 1
9191
└── var
9292
```
9393

94+
忽略文件夹
95+
96+
```bash
97+
tree -I node_modules # 忽略当前目录文件夹node_modules
98+
tree -P node_modules # 列出当前目录文件夹node_modules的目录结构
99+
tree -P node_modules -L 2 # 显示目录node_modules两层的目录树结构
100+
tree -L 2 > /home/www/tree.txt # 当前目录结果存到 tree.txt 文件中
101+
```
102+
94103
<!-- Linux命令行搜索引擎:https://jaywcjlove.github.io/linux-command/ -->

0 commit comments

Comments
 (0)
0