A fast terminal Markdown viewer for agent-heavy workflows.
catmd is designed for the "just generated some Markdown, let me inspect it now" loop:
- open a file in an interactive pager
- pipe markdown from
stdinfor one-shot rendering - navigate with vim keys
- inspect a toggleable TOC
- open links (including local markdown files)
- auto-reload with
--watch
Early v1. Internal/dev-first.
- Strong GFM support (tables, task lists, fenced code blocks, strikethrough, autolinks)
- Excellent terminal ergonomics for reading long docs
- Minimal cognitive overhead and predictable defaults
- Full GUI/TUI app complexity
- Perfect pixel-equivalence with browser HTML rendering
- Terminal image rendering protocols (kitty/iterm image APIs)
cargo install --path .Or run directly:
cargo run -- README.md# Interactive pager for files (when output is a TTY)
catmd notes.md
# Read from stdin (plain render by default)
cat README.md | catmd
# Force interactive mode
cat README.md | catmd --interactive
# Force plain output
catmd notes.md --plain
# Auto-reload when file changes
catmd notes.md --watch
# Keep up to 200 in-memory watch snapshots
catmd notes.md --watch --history 200- File input + TTY output -> interactive pager by default
stdininput -> plain output by default--interactiveforces pager mode--plainforces non-interactive output
j/k: scroll down/upCtrl-d/Ctrl-u: half-page down/upg/G: top/bottom/: search (incremental as you type)n/N: next/previous search match?: toggle keyboard shortcuts helpAorCtrl-a: quick-add a new@agenttask (appends to current file)t: toggle TOC sidebara: toggle Agent Inbox sidebar[/]: jump to previous/next headingj/k(when TOC is open): move TOC selectionj/k(when Agent Inbox is open): move task selectionEnter(when TOC is open): jump to selected TOC headingEnter(when Agent Inbox is open): jump to selected unresolved agent taskTab/Shift-Tab: next/previous linkEnter: open selected link (when TOC is closed)o: open selected link externally (browser/system opener)Backspace: go back in local markdown backstack{/}: previous/next unresolved@agenttaskv: toggle timeline dock (watch mode)h/lorLeft/Right: older/newer revision (watch mode)L: jump back to live/latest revision (watch mode)(/): previous/next changed hunk (watch mode)q: quit
- Relative
.mdlinks open insidecatmdand push the current document onto a backstack http/httpslinks open in the system browser- Other local paths open via the system opener
Images render as placeholders with alt text and path:
[image: architecture diagram] (./assets/arch.png)
--watch reloads file-backed documents when the source file changes.
- scroll position is preserved when possible
- TOC and links refresh after reload
- watch mode is only available for file input
- in-memory revision history is kept with
--history <N>(default50) - timeline dock shows revision id, timestamp,
+/-summary, touched section count, and top changed section - status bar shows
LIVEvsHISTORYmode
Agent tasks are recognized from checklist lines tagged with @agent:
- [ ] @agent clean up this section
- [x] @agent done- unresolved tasks are highlighted inline
- completed tasks are shown in a subdued style
- Agent Inbox shows unresolved items and jumps to them by line
- status bar shows
agent: open/totalcounts when tasks exist - quick capture: press
A(orCtrl-a), type task text, pressEnterto append- [ ] @agent ...
- Anchor link jumps (
#section-name) - Better table rendering and wrapping
- Theme presets
- Homebrew tap / release artifacts
MIT