In addition to being a runnable CLI tool, D2 can also be used to produce diagrams from Go programs. For examples, see ./docs/examples/lib. This blog post also demos a complete, runnable example of ...
"As planned, in the December quarter we idled the company-owned shovel, T282 trucks, and ancillary equipment, totaling 14 pieces of equipment, that are less productive and cost effective when ...