@heyhuynhgiabuu/pi-pretty
v0.2.0
Published
Pretty terminal output for pi — syntax-highlighted file reads, colored bash output, tree-view directory listings, and more.
Downloads
1,095
Maintainers
Readme
pi-pretty
A pi extension that upgrades built-in tool output in the terminal without changing tool behavior.
It currently enhances:
read: syntax-highlighted text previews with line numbers, plus inline image rendering when the terminal supports itbash: colored exit summary (exit 0/exit 1) with a preview body of command outputls/find/grep: Nerd Font file icons with tree/grouped layouts and clearer match rendering
Companion to @heyhuynhgiabuu/pi-diff for
write/editdiff rendering.
Install
pi install npm:@heyhuynhgiabuu/pi-prettyLatest release: https://github.com/buddingnewinsights/pi-pretty/releases/latest
Or load locally:
pi -e ./src/index.tsScreenshots
bash exit summary + output preview, and syntax-highlighted read text output.
ls/find/grep with Nerd Font icons and grouped/tree-oriented rendering.
read rendering an image inline in supported terminals.
Terminal support for inline images
Inline image previews are supported in Ghostty, Kitty, iTerm2, and WezTerm.
When running in tmux, pi-pretty uses passthrough escape sequences so inline image protocols still work.
Configuration
Optional environment variables:
PRETTY_THEME(default:github-dark)PRETTY_MAX_HL_CHARS(default:80000)PRETTY_MAX_PREVIEW_LINES(default:80)PRETTY_CACHE_LIMIT(default:128)PRETTY_ICONS(nerdby default, set tononeto disable icons)
Development
npm install
npm run typecheck
npm run lint
npm testLicense
MIT — huynhgiabuu
