Skip to content

Add modinfo.json schema for editor suggestions, validation #3

@BinToss

Description

@BinToss

Labels: Feature

https://raw.githubusercontent.com/BinToss/VintageStory.ModInfo.schema/refs/heads/main/VintageStory.ModInfo.schema.json
raw: https://raw.githubusercontent.com/BinToss/VintageStory.ModInfo.schema/refs/heads/main/VintageStory.ModInfo.schema.json

I've licensed it under MIT. I considered CC0 or Unlicense so the license wouldn't need to be copied, too, but those licenses wouldn't hold up in Germany.

Anyway, there are two ways this schema can be used in editors.

  1. editor workspace settings. I don't know how Rider handles it, but VSCode would need the following:
{
  "json.schemas":  [
    {
      "fileMatch": [
        "**/modinfo.json",
        "**/assets/**/modinfo.json"
      ],
      "url": "https://raw.githubusercontent.com/BinToss/VintageStory.ModInfo.schema/main/VintageStory.ModInfo.schema.json"
    }
  ]
}
  1. $schema property in the modinfo.json e.g.
{
  "$schema": "https://raw.githubusercontent.com/BinToss/VintageStory.ModInfo.schema/refs/heads/main/VintageStory.ModInfo.schema.json"
}

Ideally, Anego Studios would generate an official schema for users to validate against.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions