mergeway-cli gen-erd

Generates an Entity Relationship Diagram (ERD) of your data model.

mw gen-erd --path <output-file>

This command inspects your configuration and generates a visual representation of your entities and their relationships. It relies on Graphviz (specifically the dot command) to produce the output image.

Arguments

ArgumentDescription
--pathRequired. The path where the generated image will be saved. The file extension determines the output format (e.g., .png, .svg).

Examples

Generate a PNG image of your schema:

mw gen-erd --path schema.png

Generate an SVG:

mw gen-erd --path schema.svg

Example output, based on the full example:

ERD of the full example

Requirements

The dot executable from Graphviz needs to be installed and available in your system’s PATH.