d2

Convert text diagrams to SVG, PNG, or PDF images

brewmacoslinux
Try with needOr install directly
Source

About

Modern diagram scripting language that turns text to diagrams

Commands

d2

Examples

create a diagram from a text file$ d2 diagram.d2 diagram.svg
export diagram as PNG image$ d2 --png architecture.d2 output.png
generate PDF from diagram script$ d2 --pdf flowchart.d2 flowchart.pdf
watch file for changes and auto-render$ d2 --watch design.d2 design.svg
create diagram with custom theme$ d2 --theme 1 system.d2 system.svg