tmd graph
Exports the vault’s object relation graph in DOT format. Nodes represent objects, edges represent relations and wiki-links. Output goes to stdout for piping to Graphviz or other visualization tools.
Basic usage
Section titled “Basic usage”tmd graphOutputs a DOT digraph with all objects as nodes and all relations and wiki-links as edges.
Example output
Section titled “Example output”digraph vault { rankdir=LR; node [shape=box]; "book/clean-code-01abc" [label="📚 Clean Code"]; "person/bob-01def" [label="👤 Bob Martin"]; "book/clean-code-01abc" -> "person/bob-01def" [label="author"];}Render with Graphviz
Section titled “Render with Graphviz”tmd graph | dot -Tpng -o graph.pngtmd graph | dot -Tsvg -o graph.svgFilter by type
Section titled “Filter by type”tmd graph --type booktmd graph --type book --type personOnly includes objects of the specified types. Edges are included only when both endpoints are in the filtered set. The --type flag can be repeated.
Control edge types
Section titled “Control edge types”tmd graph --no-wikilinks # Relations onlytmd graph --no-relations # Wiki-links onlytmd graph --no-relations --no-wikilinks # Nodes onlyRelation edges are drawn as solid lines with the property name as label. Wiki-link edges are drawn as dashed lines labeled “wikilink”.
Edge behavior
Section titled “Edge behavior”- Relations: Directed edges from source to target, labeled with the relation property name. Bidirectional relations produce one edge per stored direction (e.g.,
authorandbooks). - Wiki-links: Directed dashed edges from the linking object to the target. Unresolved wiki-links (broken targets) are skipped.
- Deduplication: Edges with the same source, target, and label are deduplicated.