Peek: A Fast, Colorful, Tree-Based ls Alternative Written in Rust
Have you ever wished that ls had more colors, better layout, or tree-like display built-in?
Let me introduce Peek β a blazing-fast, customizable ls replacement built in Rust, supporting:
- β Color configuration via command line
- β Tree-style file listings
- β File size and metadata output
- β
Regex-style path filters (
*.rs,**/src, etc.) - β Persistent color settings
- β Cross-platform support (Linux and Windows)
π Why Peek?
Peek was built out of frustration with ls limitations, and inspired by tools like exa, lsd, and the beauty of Rust's safety + performance.
It provides a developer-focused and theme-aware alternative to standard directory listing.
π Features
-
peekβ list current directory -
peek -sor--sizeβ show file sizes -
peek -aor--allβ include hidden files -
peek -lor--longβ show metadata (uid/gid/perm) -
peek -tor--treeβ display tree structure -
peek -d 2or--depth 2β limit tree depth -
peek -p "*.rs"β glob filtering -
peek --set-folder-color "#FF8800"β persist folder color
And yes β the color persists across commands π
π¦ Installation
π§ Build from source
If you have Rust installed:
git clone https://github.com/tikrack/peek.git
cd peek
cargo install --path .
Or just build manually:
cargo build --release
β Cross-compile to Windows:
rustup target add x86_64-pc-windows-gnu
sudo pacman -S mingw-w64-gcc
cargo build --release --target x86_64-pc-windows-gnu
π Example Usage
peek -a -t --depth 2 -p "**/*.rs"
This will list all .rs files in tree format, including hidden files, up to 2 levels deep.
πΌ Screenshot
π§ Tech Stack
- Rust π¦
-
clapfor CLI parsing -
walkdirfor directory traversal -
regex+globsetfor pattern matching -
coloredfor styled output -
dirsandserde_jsonfor persistent config
π Repository
GitHub: github.com/tikrack/peek
Feel free to β star, fork, and contribute!
β¨ Conclusion
Peek is a simple but powerful tool that aims to bring beauty, control, and clarity to your terminal experience.
If you're a Rust enthusiast or terminal nerd β give
peeka try and share your thoughts!
Iβd love feedback, ideas, or PRs. β€οΈ
π Bonus
You can download releases for Linux and Windows directly from Releases
Thanks for reading π
https://tikrack.ir
Top comments (0)