A terminal file previewer written in Zig 0.16. Renders images, PDFs, Markdown, and text directly inside your terminal using the Kitty graphics protocol.
- Image preview (PNG, JPEG, and anything
stb_imagedecodes) - PDF preview (single page, selectable via
--page) - Markdown rendering with inline images
- Plain text dumping
- Cross-platform (Linux and macOS, x86_64 and aarch64)
brew tap ScopeSV/tap https://codeberg.org/ScopeSV/homebrew-tap.git
brew install peekThis also installs mupdf (required for PDF previews).
Grab the latest binary for your platform from the Releases page.
# Example for Linux x86_64
chmod +x peek-x86_64-linux
mv peek-x86_64-linux ~/.local/bin/peekRequires Zig 0.16.
git clone https://codeberg.org/ScopeSV/peek.git
cd peek
zig build -Doptimize=ReleaseSafe
cp zig-out/bin/peek ~/.local/bin/peek [options] <file>
| Flag | Description |
|---|---|
--page N, -p N |
PDF page to render (1-indexed) |
-h, --help |
Show help |
peek photo.png
peek document.pdf --page 3
peek notes.md
peek script.zig- A terminal that supports the Kitty graphics protocol — e.g. Kitty, Ghostty, WezTerm. Image and PDF previews will not display in terminals without it (including vim's embedded terminal).
- For PDF previews:
mutoolmust be on yourPATH. Install it via:- Debian/Ubuntu:
apt install mupdf-tools - Arch:
pacman -S mupdf-tools - Alpine:
apk add mupdf-tools - Fedora:
dnf install mupdf - macOS (Homebrew):
brew install mupdf
- Debian/Ubuntu:
Other formats (images, Markdown, text) work without any external tools.