Treefilesize |top| Official
Example:
$ treefilesize ~/Downloads Downloads/ ├── resume.pdf (340 KB) ├── video.mp4 (1.2 GB) ⚠️ └── archive/ (800 MB) 💡 Pro tip: Combine with grep or --du flag in standard tree .
treefilesize is essentially a wrapper script (bash, Python, or PowerShell) that traverses directories and outputs a tree where each file shows its size and directories show aggregated or individual sizes. treefilesize
project/ ├── README.md (1.2 KB) ├── data/ (24 MB) │ ├── raw.csv (18 MB) │ ├── clean.csv (6 MB) ├── scripts/ (8 KB) │ ├── analyze.py (4 KB) │ ├── utils.py (4 KB) └── output/ (512 MB) └── results.pdf (512 MB) Save this as treefilesize and add to your PATH:
(more customizable):
Meet treefilesize – a simple trick on top of the classic tree command.
Want only large files? Pipe to grep: tree -h --du | grep "M\|G" Want only large files
$ treefilesize ~/Projects -d 2 -s Title: Find Large Files Instantly with treefilesize