Skip to content

Commit

Permalink
chore(sty): Run prettier on metaschema.json to reduce future diffs
Browse files Browse the repository at this point in the history
  • Loading branch information
effigies committed Apr 26, 2024
1 parent 46d6ffa commit 0c6e8ce
Showing 1 changed file with 110 additions and 66 deletions.
176 changes: 110 additions & 66 deletions src/metaschema.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
"properties": {
"associations": {
"type": "object",
"patternProperties":
{
"patternProperties": {
"^[a-zA-Z0-9_]+$": {
"type": "object",
"properties": {
Expand All @@ -28,7 +27,8 @@
"anyOf": [
{
"type": "string"
}, {
},
{
"type": "array",
"items": {
"type": "string"
Expand Down Expand Up @@ -126,23 +126,23 @@
"additionalProperties": false
},
"common_principles": {
"type": "object",
"patternProperties": {
"^[a-zA-Z0-9_]+$": {
"type": "object",
"properties": {
"display_name": {
"type": "string"
},
"description": {
"type": "string"
}
},
"required": ["display_name", "description"],
"additionalProperties": false
},
"additionalProperties": false
}
"type": "object",
"patternProperties": {
"^[a-zA-Z0-9_]+$": {
"type": "object",
"properties": {
"display_name": {
"type": "string"
},
"description": {
"type": "string"
}
},
"required": ["display_name", "description"],
"additionalProperties": false
},
"additionalProperties": false
}
},
"datatypes": {
"type": "object",
Expand Down Expand Up @@ -191,7 +191,13 @@
"type": "array"
}
},
"required": ["name", "display_name", "description", "type", "format"],
"required": [
"name",
"display_name",
"description",
"type",
"format"
],
"additionalProperties": false
}
},
Expand Down Expand Up @@ -312,7 +318,7 @@
"$ref": "http://json-schema.org/draft-07/schema#/properties/type"
}
},
"required": ["name","display_name", "description"]
"required": ["name", "display_name", "description"]
}
},
"additionalProperties": false
Expand Down Expand Up @@ -358,8 +364,20 @@
}
}
},
"required": ["columns", "common_principles", "datatypes", "entities", "enums", "extensions", "files", "formats", "metadata", "modalities", "suffixes"],
"additionalProperties": false
"required": [
"columns",
"common_principles",
"datatypes",
"entities",
"enums",
"extensions",
"files",
"formats",
"metadata",
"modalities",
"suffixes"
],
"additionalProperties": false
},
"rules": {
"type": "object",
Expand All @@ -376,20 +394,20 @@
"issues": {
"type": "object",
"properties": {
"code": {"type": "string"},
"message": {"type": "string"},
"level": {"enum": ["error", "warning"]}
"code": { "type": "string" },
"message": { "type": "string" },
"level": { "enum": ["error", "warning"] }
},
"required": ["code", "message", "level"],
"additionalProperties": false
},
"selectors": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
},
"checks": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
}
},
"required": ["checks", "selectors"]
Expand Down Expand Up @@ -476,7 +494,7 @@
"^derivatives$": {
"type": "object",
"properties": {
"common_derivatives": {"$ref": "#/definitions/sidecar"}
"common_derivatives": { "$ref": "#/definitions/sidecar" }
},
"required": ["common_derivatives"],
"additionalProperties": false
Expand All @@ -498,9 +516,7 @@
"$ref": "#/definitions/tabular_data"
}
},
"required": [
"common_derivatives"
],
"required": ["common_derivatives"],
"additionalProperties": false
},
"^(?!derivatives$)[a-z_]+$": {
Expand All @@ -511,7 +527,7 @@
},
"common_principles": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
},
"dataset_metadata": {
"type": "object"
Expand All @@ -521,17 +537,17 @@
},
"entities": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
},
"errors": {
"type": "object",
"patternProperties": {
"^[a-zA-Z0-9_]+$": {
"type": "object",
"properties": {
"code": {"type": "string"},
"message": {"type": "string"},
"level": {"enum": ["error", "warning"]},
"code": { "type": "string" },
"message": { "type": "string" },
"level": { "enum": ["error", "warning"] },
"selectors": {
"type": "array",
"items": {
Expand All @@ -553,7 +569,7 @@
"properties": {
"datatypes": {
"type": "array",
"items": {"pattern": "^[a-z]+$"}
"items": { "pattern": "^[a-z]+$" }
}
},
"required": ["datatypes"],
Expand All @@ -563,15 +579,15 @@
}
},
"required": [
"entities",
"files",
"sidecars",
"tabular_data",
"common_principles",
"dataset_metadata",
"directories",
"errors",
"modalities"
"entities",
"files",
"sidecars",
"tabular_data",
"common_principles",
"dataset_metadata",
"directories",
"errors",
"modalities"
],
"additionalProperties": false
},
Expand All @@ -593,14 +609,14 @@
"patternProperties": {
"^[a-z]+$": {
"anyOf": [
{"enum": ["optional", "required"]},
{ "enum": ["optional", "required"] },
{
"type": "object",
"properties": {
"level": {"enum": ["optional", "required"]},
"level": { "enum": ["optional", "required"] },
"enum": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
}
},
"required": ["level", "enum"]
Expand All @@ -618,24 +634,38 @@
"properties": {
"selectors": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
},
"fields": {
"type": "object",
"patternProperties": {
"^[a-zA-Z0-9_]+$": {
"anyOf": [
{"enum": ["recommended", "optional", "required", "deprecated"]},
{
"type": "object",
"enum": [
"recommended",
"optional",
"required",
"deprecated"
]
},
{
"type": "object",
"properties": {
"level": {"enum": ["recommended", "optional", "required", "deprecated"]},
"level_addendum": {"type": "string"}
"level": {
"enum": [
"recommended",
"optional",
"required",
"deprecated"
]
},
"level_addendum": { "type": "string" }
},
"required": ["level", "level_addendum"],
"additionalProperties": false
},
{"pattern": "recommended.*"}
{ "pattern": "recommended.*" }
]
}
},
Expand All @@ -656,25 +686,39 @@
"properties": {
"selectors": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
},
"columns": {
"type": "object",
"patternProperties": {
"^[a-zA-Z0-9_]+$": {
"anyOf": [
{"enum": ["recommended", "optional", "required", "deprecated"]},
{
"type": "object",
"enum": [
"recommended",
"optional",
"required",
"deprecated"
]
},
{
"type": "object",
"properties": {
"level": {"enum": ["recommended", "optional", "required", "deprecated"]},
"level_addendum": {"type": "string"},
"description_addendum": {"type": "string"}
"level": {
"enum": [
"recommended",
"optional",
"required",
"deprecated"
]
},
"level_addendum": { "type": "string" },
"description_addendum": { "type": "string" }
},
"required": ["level"],
"additionalProperties": false
},
{"pattern": "recommended.*"}
{ "pattern": "recommended.*" }
]
}
},
Expand All @@ -683,10 +727,10 @@
"additional_columns": {
"type": "string"
},
"index_columns": {"type": "array", "items": {"type": "string"}},
"index_columns": { "type": "array", "items": { "type": "string" } },
"initial_columns": {
"type": "array",
"items": {"type": "string"}
"items": { "type": "string" }
}
},
"required": ["selectors", "columns"],
Expand Down

0 comments on commit 0c6e8ce

Please sign in to comment.