Lightweight tool for displaying directory structures in a simple, readable format
Here's what it looks like when running ztree demo from the project root:
Clone the repository:
git clone https://github.com/setPedro/zig-tree.git
cd zig-treeBuild and install:
zig build-exe src/main.zig -O ReleaseSmall --name ztree
sudo mv ztree /usr/local/bin/
sudo chmod +x /usr/local/bin/ztreeThese commands:
- Compile your program into an executable named ztree
- Move it to a system-wide directory (/usr/local/bin/)
- Make it executable
zig build-exe src/main.zig -O ReleaseSmall --name ztree.exeAfter building, either:
- Move
ztree.exeto a directory in your system PATH - Or add the directory containing
ztree.exeto your PATH environment variable
Once installed, you can use ztree from anywhere.
-
Display the current directory structure:
ztree -
Display a specific directory:
ztree <path>