首先需要安装tree这个软件

sudo apt install tree

 

tree -L 2  target_dir/

2代表列举的目录结构深度

ubuntu tree 查看目录结构

 

相关文章: