TUT
TUT reads one finite UTF-8 text document or a reflowable EPUB, presents it safely and gets out of the way. Written in Rust.
View sourceThe problem
I wanted a terminal reader that is safe by construction. It never interprets a document’s control sequences, never fetches anything remote and never runs book scripts.
How it works
- Unicode-grapheme-aware display with automatic soft wrapping, and EPUB 2 and 3 main reading order for DRM-free reflowable books.
- Vim and pager style navigation, exact literal search with highlighting, and bounded numeric prefixes such as 12j.
- Layout, indexing, rendering and search run incrementally, so input and signals stay observable during expensive work.
- Terminal resize, suspend, continue, EOF, hangup and interrupt are handled explicitly, and the terminal is always restored.
- Control and bidirectional-formatting characters are shown instead of executed or silently applied.
- Optional local session metrics leave out document text, queries, paths and individual keys.
Built with
- Rust
- Unicode
- EPUB
- POSIX terminals
