fusesoc icon indicating copy to clipboard operation
fusesoc copied to clipboard

provide schema as json

Open WisniewskiP opened this issue 1 year ago • 0 comments

currently schema is defined inside fusesoc/capi2/json_schema.py as a multi line string variable. to use schema outside fusesoc it would be easier to have it as standard JSON file.

Use case: for editing yaml files I'm using VSCode with redhat.vscode-yaml extension that supports json schema and provides validation inside editor.

at this moment I just saved schema info JSON file and then inside settings, I configured that *.core should use this schema. following setting are needed to make it work:

    "yaml.schemas": {
        "/path/to/fusesoc.schema.json": "*.core"
    },
    "files.associations": {
        "*.core": "yaml"
    }

after that I get suggestions and validation during editing of core file.

WisniewskiP avatar Jun 26 '24 18:06 WisniewskiP