These changes are for the language server in d2-vscode. When the D2_LSP_MODE environment variable is set, the d2 cli will read the d2 file, produce the ast (and possible errors), convert it to JSON, print it out to stdout, then terminate. This was done this way to keep the changes to the d2 cli code to a minimum. PR for d2-vscode to come after this is accepted |
||
|---|---|---|
| .. | ||
| compile.go | ||
| compile_test.go | ||
| doc.go | ||