Doc Discovery
Starts from one Markdown file, finds a project root, and gathers related docs while skipping cache and dependency directories.
local Markdown docs, offline Mermaid, mdBook today
A small local Markdown viewer that discovers related docs, generates an mdBook workspace, embeds Mermaid support, and opens the rendered page from `.cache/mdview`.
The current project scope is intentionally narrow: manage local Markdown docs as an mdBook, with generated navigation and offline Mermaid rendering.
Starts from one Markdown file, finds a project root, and gathers related docs while skipping cache and dependency directories.
Creates `book.toml`, `SUMMARY.md`, and a mirrored source tree under `.cache/mdview`, then runs `mdbook build`.
Embeds local Mermaid JavaScript assets into the generated book so diagrams work without CDN access.
Uses `title`, `parent`, and `weight` frontmatter to shape the mdBook summary and automate ToC creation.
`mdview SomeDoc.md` prints the file to your terminal; `mdview book open SomeDoc.md` builds the whole-project documentation book and opens the generated HTML from `.cache/mdview`.
The implementation stays compact, avoids Electron and TypeScript, and uses external tools only where they already fit the job.
mdview is currently a doc manager for mdBook. It prepares a temporary book workspace and lets mdBook do the final HTML rendering.
$ mdview book open docs/Project.md root /home/uwe/projects/mdview pages 5 built .cache/mdview/book opened .cache/mdview/book/docs/Project.html $ mdview book build AGENTS.md $ mdview docs/Project.md
The long-term direction is broader than mdBook: mdview should become
a Markdown docs browser that feels like cat plus
tree, but
interactive and built for connected documentation.
Likecatandtree, but for Markdown projects.