From 93649197e97d430d39399f5a08b0ae9345a30409 Mon Sep 17 00:00:00 2001 From: Ton Date: Wed, 12 Mar 2025 16:06:02 +0100 Subject: [PATCH] a how-to vscode and autocompile on save --- tutorial/vscode.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 tutorial/vscode.md diff --git a/tutorial/vscode.md b/tutorial/vscode.md new file mode 100644 index 0000000..1b24e91 --- /dev/null +++ b/tutorial/vscode.md @@ -0,0 +1,24 @@ +## Editing y(a)ml files with VSCode + +If you already use vscode as your editor you are in luck. Steffano wrote a very handy how-to setup run-on-save extesion for vscode. + +https://www.stefanocottafavi.com/vscode_wireviz/ + + +If you want to use the prepend parameter so you can use a parent document (components.yml) with all your components defined you could do the following. + +```yaml +"settings": { + "emeraldwalk.runonsave": { + "commands": [ + { + "match": "\\.yml$", + "cmd": "wireviz --prepend components.yml ${file} -f h" + }, + + ] + } +} +``` + +(the -f h instructs wireviz to only produce a html file. Do a wireviz -h for a overview of all the parameters) \ No newline at end of file