1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-23 17:22:08 +02:00
tldr/pages/linux/tree.md
2016-09-16 11:41:23 +01:00

27 lines
559 B
Markdown

# tree
> Show the contents of the current directory as a tree.
- Show files and directories up to 'num' levels of depth (where 1 means the current directory):
`tree -L {{num}}`
- Show directories only:
`tree -d`
- Show hidden files too:
`tree -a`
- Print the tree without indentation lines, showing the full path instead (use `-N` to not escape whitespace and special characters):
`tree -i -f`
- Print the size of each node next to it, in human-readable format:
`tree -s -h`
- Filter the tree using a wildcard (glob) pattern:
`tree -P {{*.txt}}`