File tree generator
Turn a list of file paths into a Unix tree-style directory listing with directories first, automatic de-duplication, and file/folder/depth counts for docs and READMEs.
Runs in your browserEvery computation happens in your browser — your data never leaves this device.
One path per line. Windows backslashes, ./ prefixes and trailing slashes are normalised, and duplicate paths are kept once.
Directory tree
Connectors match the Unix tree command, ready to paste into a README code block.
Paste file paths to see the directory tree
What this tool does
- Turn a find / git ls-files output into a README directory tree
- Inspect the structure, folder count and maximum depth of a path list
- Clean duplicate lines before comparing two listings
Example
Input
src/index.ts src/tools/uuid-gen/uuid-gen.ts README.md
Output
. ├── src/ │ ├── tools/ │ │ └── uuid-gen/ │ │ └── uuid-gen.ts │ └── index.ts └── README.md
Three paths become one tree: directories sort before files, connectors use ├── / └── and nested levels continue with │. Stats: 3 files, 3 directories, max depth 4.
Frequently asked questions
Does it read my disk?
No. It only processes the pasted path list, never touches the file system and uploads nothing. Directories and files are inferred purely from the path levels, so the tool cannot know what really exists on your machine.
How are directories and files distinguished?
By position: the last level of each path is treated as a file and every earlier level as a directory, so a/b/c.txt yields directories a and b plus the file c.txt. A name that appears both as directory and file is handled once as a file.
What about duplicates, backslashes and relative paths?
Duplicate paths are kept once and counted. Windows backslashes become /, and leading ./ or /, trailing slashes and inner /./ are normalised while /../ pops a level. Up to 5000 paths per run.
Keywords:file tree generatordirectory listingoffline