You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
393 B
17 lines
393 B
import json
|
|
import jsonschema
|
|
import os.path
|
|
import sys
|
|
|
|
|
|
with open(sys.argv[1], "r", encoding="utf-8-sig") as f:
|
|
contents = json.load(f)
|
|
|
|
schema_file = os.path.join(
|
|
os.path.dirname(__file__),
|
|
"..", "..", "..", "Help", "manual", "presets", "schema.json")
|
|
with open(schema_file, "r", encoding="utf-8") as f:
|
|
schema = json.load(f)
|
|
|
|
jsonschema.validate(contents, schema)
|