OCAMLDOT(1)
π OCAMLDOT(1) π
okay bestie, welcome to the General Commands Manual, section 1, where we're talking about ocamldot β yes, the little icon that makes your OCaml dependency spaghetti look like an actual graph β¨
πΈ NAME πΈ
ocamldot β generate dependency graphs of ocaml programs π¦
β¨ SYNOPSIS β¨
ocamldot [options] <dependency-file>
π DESCRIPTION π
okay so first things first: this manual page documents briefly the ocamldot command. brief. like a text from your bestie that just says "call me". π
ocamldot generates program dependency graphs for ocaml programs. that's the whole vibe. it takes your dependency info and hands you back a graph, and then a separate program called dot renders that graph into something your eyeballs can actually enjoy. so ocamldot makes the graph, dot makes it pretty. teamwork. slay. π
Ocamldot is designed to process the output of ocamldep. that's its whole thing, that's its moment, that's its main character energy. a typical use would be:
ocamldep *.ml | ocamldot > dep.dot
or, if you're the type who likes to save your steps like a little archive goblin π:
ocamldep *.ml > .depend
ocamldot .depend > dep.dot
π OPTIONS π
-fullgraphβ draw the full graph. no cap. (the default is to draw only the kernel β more on that lil guy below π)-landscapeβ output in landscape format. (the default is portrait, so if your graph is giving tall-girl energy, this is your fix β¨)-lrβ draw the graph from left to right. (the default is top to bottom, so this is the "rotate your whole worldview" option π)-r <r>β use<r>as a root in the graph; nodes reachable from<r>will be shown. so it's like, you pick the main character, and only the people in their orbit get to appear on screen π
π§ a lil note on the kernel π§
not me explaining graph theory in a manpage but here we are, bestie, it's giving educational π«Ά
The transitive kernel of a dag is the smallest subset of the dag whose transitive closure is the same as the transitive closure of the dag.
okay that's the formal version. here's the vibe check version: for example, the kernel of A->B, A->C, B->C is just the two edges A->B, B->C. because A->C was already implied β it's the redundancy, and the kernel said "we don't need that one, it's derivative, it's a rerun" π so by default ocamldot keeps only the edges that actually matter, and if you want every single one, that's what -fullgraph is for. periodt.
π₯ SEE ALSO π₯
π AUTHOR π
Trevor Jim <trevor@research.att.com>
β reminder bestie:ocamldotwrites the graph,dotrenders it. don't expect one to do the other's job, they're not that kind of relationship π
and that's the whole page!! this one lives in section 1 of the General Commands Manual β shoutout to the classic manpage header/footer combo, iconic, no notes, mwah π β¨ πΈ
π¦ where this page comes from
- debian bookworm: ocaml-tools 20120103-9 Β· BSD-3-Clause
- debian trixie: ocaml-tools 20120103-13 Β· BSD-3-Clause
- ubuntu jammy: ocaml-tools 20120103-9 Β· BSD-3-Clause
- ubuntu noble: ocaml-tools 20120103-10 Β· BSD-3-Clause
- ubuntu questing: ocaml-tools 20120103-13
- ubuntu resolute: ocaml-tools 20120103-14build1 Β· BSD-3-Clause
- ubuntu stonking: ocaml-tools 20120103-15build1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms